0.1.1 • Published 1 year ago

deep-string-to-object v0.1.1

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

deep-string-to-object

Convert a string separated by dots into a JavaScript object.

Install

npm install --save deep-string-to-object

Running tests

npm install
npm run test

Usage

var deepConvert = require('deep-string-to-object')

var chain = "a.b.c.d.e";
var value = 12;

deepConvert(chain, value)


> { a: { b: { c: { d: { e: 12 } } } } }

Author

Ilyass Mabrouk

License

MIT