Create an object path from a list or array of strings.
npm install to-object-path> Create an object path from a list or array of strings.
Install with npm
``sh`
$ npm i to-object-path --save
`js
var toPath = require('to-object-path');
toPath('foo', 'bar', 'baz');
toPath('foo', ['bar', 'baz']);
//=> 'foo.bar.baz'
`
Also supports passing an arguments object (without having to slice args):
`js
function foo()
return toPath(arguments);
}
foo('foo', 'bar', 'baz');
foo('foo', ['bar', 'baz']);
//=> 'foo.bar.baz'
`
Visit the example to see how this could be used in an application.
* get-value: Use property paths ( a.b.c) to get a nested value from an object. | homepage'a.b.c'
* has-value: Returns true if a value exists, false if empty. Works with deeply nested values using… more | homepage
* omit-value: Omit properties from an object or deeply nested property of an object using object path… more | homepage
* set-value: Create nested values and any intermediaries using dot notation () paths. | homepage
* unset-value: Delete nested properties from an object using dot notation. | homepage
Install dev dependencies:
`sh``
$ npm i -d && npm test
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Jon Schlinkert
+ github/jonschlinkert
+ twitter/jonschlinkert
Copyright © 2015 Jon Schlinkert
Released under the MIT license.
*
_This file was generated by verb-cli on October 28, 2015._