es-toolkit
Version:
A state-of-the-art, high-performance JavaScript utility library with a small bundle size and strong type annotations.
14 lines (11 loc) • 333 B
JavaScript
import { trimStart as trimStart$1 } from '../../string/trimStart.mjs';
function trimStart(str, chars, guard) {
if (str == null) {
return '';
}
if (guard != null || chars == null) {
return str.toString().trimStart();
}
return trimStart$1(str, chars.toString().split(''));
}
export { trimStart };