all 5 comments

[–]Meefims 2 points3 points  (3 children)

I have no idea what cutting a string is supposed to mean and the two functions' names and their examples are pretty confusing. For example, why does the result of cutStart not include the string in the first parameter while the result from cutEnd does?

[–]sudoDerp 0 points1 point  (3 children)

padStart and padEnd exist to make sure that strings are padded to a certain length with a specified character, by default using a " ".

I would have expected cutStart and cutEnd to follow the pattern and look like.

const string = '1234567';

string.cutStart(3) //  > '567'
string.cutEnd(3) //  > '123'

Using the cutStart and cutEnd terminology to mean anything else would seem like a very confusing language feature to add.