forget
missing method
Lodash Lodash includes great has
, get
and set
methods, but NOT one that will remove
value with the same recursive way.
forget
.
Introducing It supports same nested syntax as get
, set
and has
in Lodash module and removes appropriate found value.
Installation
npm i lodash-forget --save
How to use
var forget = object = 'a': 'b': 'c': 3 'd': 1 2 ; ;// => { 'a': { 'b': { 'd': [1, 2] } } }; ;// => { 'a': { 'b': { 'd': [2] } } }; ;// => {}; // Or use lodash mixin_;