deep-check
Check that properties of a deeply-nested object exist.
install
$ npm install deep-check
usage
The schema used to check if values are present can be itself a deeply nested object:
var deepCheck = var data = fruit: citrus: lemons:10 oranges:12 orders: settings: id:12 var schema = fruit: citrus: lemons:true weight:true orders: settings:true history:true var missing = console // ['fruit.citrus.weight', 'orders.history']
Or you can use an array with dot-notation:
var schema = 'fruit.citrus.lemons' 'fruit.apples' 'orders.settings' 'orders.history' var missing = console // ['fruit.apples', 'orders.history']
license
MIT