Hi, Just got a question why don't we polyfill `trimLeft` and `trimRight` for strings, and have only `trim` (and the answer is -- because it's not part of ES5/ES6).
Just thinking could it be a valid cases when a dev may want to trim only form right still keeping e.g. the precalculated padding on the left (seems legit)? MDN mentions them [1], [2], though as non-standard. What stopping both methods to be included? [1] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/trimLeft [2] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/TrimRight Dmitry
_______________________________________________ es-discuss mailing list es-discuss@mozilla.org https://mail.mozilla.org/listinfo/es-discuss