Created
October 1, 2014 19:38
-
-
Save techniq/3b3756f66369fe7ab3ab to your computer and use it in GitHub Desktop.
Find unique object keys across an array of objects
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var _ = require('lodash'); | |
var allKeys = _.map(items, function(i) { return Object.keys(i); }); | |
var uniqueKeys = _.uniq(_.flatten(allKeys)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment