0.0.1 • Published 10 years ago
eivindfjeldstad-dot v0.0.1
dot
Get and set object properties with dot notation
Installation
$ component install eivindfjeldstad/dot
API
dot.set(object, path, value)
dot.set(obj, 'cool.aid', 'rocks');
assert(obj.cool.aid === 'rocks');
dot.get(object, path)
var value = dot.get(obj, 'cool.aid');
assert(value === 'rocks');
License
MIT
0.0.1
10 years ago