Bachir Soussi Chiadmi cefd1c2ad0 updated sys and created publi | 7 tahun lalu | |
---|---|---|
.. | ||
LICENSE | 7 tahun lalu | |
README.md | 7 tahun lalu | |
index.js | 7 tahun lalu | |
package.json | 7 tahun lalu |
Iterate over the own and inherited enumerable properties of an object, and return an object with properties that evaluate to true from the callback. Exit early by returning
false
.
npm i for-own --save
npm test
var forOwn = require('for-own');
var obj = {a: 'foo', b: 'bar', c: 'baz'};
var values = [];
var keys = [];
forOwn(obj, function (value, key, o) {
keys.push(key);
values.push(value);
});
console.log(keys);
//=> ['a', 'b', 'c'];
console.log(values);
//=> ['foo', 'bar', 'baz'];
Jon Schlinkert
Copyright (c) 2014 Jon Schlinkert, contributors. Released under the MIT license
This file was generated by verb-cli on September 20, 2014.