/ tools / slug

Turkish slug generator.

Most slugifiers mangle Turkish. Yiğit becomes yi-it because ğ gets dropped instead of transliterated. This one uses a small Turkish character map before NFKD normalisation, so Yiğit Tanrıverdi ends up as yigit-tanriverdi, the way it should.

Pure client-side. Nothing is sent to any server.

What it does, in order
  1. 1Replace Turkish characters (ğ, ı, ş, ç, ö, ü and their uppercase forms) with their closest ASCII equivalents.
  2. 2Unicode NFKD normalise; strip remaining combining marks.
  3. 3Lowercase.
  4. 4Drop quotes and apostrophes (so what's becomes whats, not what-s).
  5. 5Collapse anything non-alphanumeric into a single hyphen.
  6. 6Trim leading / trailing hyphens.

Source: src/lib/slug.ts — same module the rest of the site uses for its URLs.

Built because nothing else handled Yiğit correctly.