Lodash - gte method
Syntax
_.gte(value, other)
Checks if value is greater than or equal to other.
Arguments
value (*) − The value to compare.
other (*) − The other value to compare.
Output
(boolean) − Returns true if value is greater than or equal to other, else false.
Example
var _ = require('lodash');
console.log(_.gte(3, 1));
console.log(_.gte(3, 3));
console.log(_.gte(1, 3));
Save the above program in tester.js. Run the following command to execute this program.
Command
\>node tester.js
Output
true true false
lodash_lang.htm
Advertisements