epiphany/node_modules/ends-with/benchmark/implementations/re-search.js
2023-12-09 22:48:07 -08:00

8 lines
148 B
JavaScript

'use strict';
module.exports = function(a, b) {
a = String(a);
b = String(b);
var re = new RegExp(b + '$');
return a.search(re) !== -1;
};