You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The $tail function execution time is positively correlated with length of string because of str[str.length -1].
The longer of the string, the longer time it takes.
exportconst$tail=(str: string): string=>str[str.length-1]==="," ? str.substring(0,str.length-1) : str;// I think it should be exportconst$tail=(str: string,hasLastExpresstion: boolean)=>hasLastExpresstion ? str : str.substring(0,-1)
As the generator knows the last prop expression is undefined === input.mobile, just pass second argument undefined !== input.mobile to $tail.
After do this, result.duration reduce to 1733.192805 on my machine.
The text was updated successfully, but these errors were encountered:
The
$tail
function execution time is positively correlated with length of string because ofstr[str.length -1]
.The longer of the string, the longer time it takes.
As the generator knows the last prop expression is
undefined === input.mobile
, just pass second argumentundefined !== input.mobile
to$tail
.After do this, result.duration reduce to
1733.192805
on my machine.The text was updated successfully, but these errors were encountered: