I have to remove unwanted object properties that do not match my model. How can I achieve it with Lodash?
My model is:
var model = { fname: null, lna
Lodash unset is suitable for removing a few unwanted keys.
unset
const myObj = { keyOne: "hello", keyTwo: "world" } unset(myObj, "keyTwo"); console.log(myObj); /// myObj = { keyOne: "hello" }