react-widgets
Version:
An à la carte set of polished, extensible, and accessible inputs built for React
41 lines (35 loc) • 762 B
JavaScript
;
exports.__esModule = true;
var common = {
eq: function eq(a, b) {
return a === b;
},
neq: function neq(a, b) {
return a !== b;
},
gt: function gt(a, b) {
return a > b;
},
gte: function gte(a, b) {
return a >= b;
},
lt: function lt(a, b) {
return a < b;
},
lte: function lte(a, b) {
return a <= b;
},
contains: function contains(a, b) {
return a.indexOf(b) !== -1;
},
startsWith: function startsWith(a, b) {
return a.lastIndexOf(b, 0) === 0;
},
endsWith: function endsWith(a, b) {
var pos = a.length - b.length,
lastIndex = a.indexOf(b, pos);
return lastIndex !== -1 && lastIndex === pos;
}
};
exports["default"] = common;
module.exports = exports["default"];