sindresorhus / slugify

Slugify a string

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Truncate string input?

Catsvilles opened this issue · comments

Is it possible to truncate the output of the "slugified" string if it's way too long? Thanks!

Why does the package need to handle that? You can just slugifiedString.slice(0, maxLength).

@sindresorhus Thanks for the reply, you are right, I should just truncate it myself separately. I guess, I just got used to previous stack/package where it was done automatically. But ofc there is no need for this package to do it too. Cheers! :)