Check if a given value is within a defined scope (inclusive of the scope's boundaries).
The value to check.
An array defining the range [min, max] where value should be compared against.
value
inScope(0, [0, 1]); // => trueinScope(1, [0, 1]); // => trueinScope(2, [0, 1]); // => falseinScope(-1, [0, 1]); // => false Copy
inScope(0, [0, 1]); // => trueinScope(1, [0, 1]); // => trueinScope(2, [0, 1]); // => falseinScope(-1, [0, 1]); // => false
Check if a given value is within a defined scope (inclusive of the scope's boundaries).