Bump to v4.17.21

This commit is contained in:
Benjamin Tan
2021-02-20 23:33:13 +08:00
parent 42e2585e5f
commit 11eb817cdf
11 changed files with 71 additions and 18 deletions

19
_baseTrim.js Normal file
View File

@@ -0,0 +1,19 @@
import trimmedEndIndex from './_trimmedEndIndex.js';
/** Used to match leading whitespace. */
var reTrimStart = /^\s+/;
/**
* The base implementation of `_.trim`.
*
* @private
* @param {string} string The string to trim.
* @returns {string} Returns the trimmed string.
*/
function baseTrim(string) {
return string
? string.slice(0, trimmedEndIndex(string) + 1).replace(reTrimStart, '')
: string;
}
export default baseTrim;