astro-ghostcms/.pnpm-store/v3/files/96/8e775b052f6777021b1cbe3fe6e...

16 lines
463 B
Plaintext
Raw Normal View History

2024-02-14 14:10:47 +00:00
'use strict';
var implementation = require('./implementation');
module.exports = function getPolyfill() {
if (!String.prototype.trimStart && !String.prototype.trimLeft) {
return implementation;
}
var zeroWidthSpace = '\u200b';
var trimmed = zeroWidthSpace.trimStart ? zeroWidthSpace.trimStart() : zeroWidthSpace.trimLeft();
if (trimmed !== zeroWidthSpace) {
return implementation;
}
return String.prototype.trimStart || String.prototype.trimLeft;
};