1
0
mirror of https://github.com/JuanCanham/HackMyResume.git synced 2024-11-13 04:50:09 +00:00

Add string convenience method.

This commit is contained in:
hacksalot 2015-12-20 18:42:02 -05:00
parent 87b3bbe785
commit cdbb264093

View File

@ -17,3 +17,7 @@ String.isNullOrWhitespace = function( input ) {
String.prototype.endsWith = function(suffix) {
return this.indexOf(suffix, this.length - suffix.length) !== -1;
};
String.is = function( val ) {
return typeof val === 'string' || val instanceof String;
};