Javascript String endsWith() method

Description

Javascript String endsWith() method


String.prototype.endsWith = function () {
    var suffix = arguments[0];
    return this.indexOf(suffix, this.length - suffix.length) !== -1;
};



PreviousNext

Related