Adds the trim() function to all Strings
In Brief:
This will remove leading/trailing white spaces from a String.... more
Language
JavaScript
# 's
1String.prototype.trim = function() {
2 return this.replace(/^\s+|\s+$/, "");
3}
This will remove leading/trailing white spaces from a String.
Included in this Library
Add a Comment