only-default
v1.1.0
Published
Return whitelisted properties of an object, with default value.
Downloads
2
Readme
node-only-default
Return whitelisted properties of an object, with default value.
Quick Start
$ npm install only-default --save
const only = require('only-default');
const obj = {
name: 'aaa',
age: '20'
};
console.log(only(obj, {name: '', sex: -1}));