A callback function to mapValues. It should return new value, optionally may return exported mapValuesUnset
value to unset a property in the target the object.
functionfn(value, key) { returnvalue * 5; } // all properties will be multiplied
Example
functionfn(value, key) { if (key === "name") { returnmapValuesUNSET; } returnvalue.toUpperCase(); } // will upper case all properties and filter out name property
A callback function to mapValues. It should return new value, optionally may return exported mapValuesUnset value to unset a property in the target the object.