Created
September 25, 2024 23:55
-
-
Save OrderAndCh4oS/518faeb2d851955e1e409210cdb2b48a to your computer and use it in GitHub Desktop.
Revisions
-
OrderAndCh4oS created this gist
Sep 25, 2024 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,9 @@ const slugify = (str: string) => str .normalize("NFD") .replace(/[^\w\s]/g, '') .trim() .replace(/\s+/g, '-') .toLowerCase() ; console.log(slugify(' Blhä+ LFgha+áaf. asfaASF aFsfsf. '));