var log = (0, _lodash.memoize)(function (message) {
console.log((0, _ansicolors.red)('WARNING:'), message);
});
I am facing difficulty in understanding the above code. This code was written in JavaScript.
var log = (0, _lodash.memoize)(function (message) {
console.log((0, _ansicolors.red)('WARNING:'), message);
});
I am facing difficulty in understanding the above code. This code was written in JavaScript.
Basically the code (0, _lodash.memoize)
eliminates the need to make a new instance
and directly gives you the value of function rather than reference.