Skip to content

Commit

Permalink
Includes `\uFEFF' to the list of whitespace characters.
Browse files Browse the repository at this point in the history
  • Loading branch information
robotlolita committed Aug 6, 2011
1 parent 0907972 commit f3762cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion es5-shim.js
Expand Up @@ -868,7 +868,7 @@ if (isNaN(Date.parse("T00:00"))) {
if (!String.prototype.trim) {
// http://blog.stevenlevithan.com/archives/faster-trim-javascript
var whitespace = "[\x09\x0A\-\x0D\x20\xA0\u1680\u180E\u2000-\u200A"
+ "\u202F\u205F\u3000\u2028\u2029]"
+ "\u202F\u205F\u3000\u2028\u2029\uFEFF]"

var trimBeginRegexp = new RegExp("^" + whitespace + "*");
var trimEndRegexp = new RegExp(whitespace + "*$");
Expand Down

0 comments on commit f3762cf

Please sign in to comment.