RepoPilot

What unicode/non-Latin test cases are covered?

About sindresorhus/slugify · 2 messages · last activity 6/15/2026

Question

What unicode/non-Latin test cases are covered?

RepoPilot

The repository has comprehensive test coverage for multiple non-Latin scripts and Unicode characters. Here are the test cases covered:

German umlauts [test.js:L111-L113]:

  • Tests ä ö ü Ä Ö Ü ß with separator option

Vietnamese [test.js:L115-L117]:

  • Tests ố Ừ Đ

Arabic [test.js:L119-L121]:

  • Tests ث س و

Persian/Farsi [test.js:L123-L125]:

  • Tests چ ی پ

Urdu [test.js:L127-L129]:

  • Tests ٹ ڈ ھ

Pashto [test.js:L131-L133]:

  • Tests ګ ړ څ

Russian [test.js:L135-L137]:

  • Tests Ж п ю

Romanian [test.js:L139-L141]:

  • Tests ș Ț

Turkish [test.js:L143-L145]:

  • Tests İ ı Ş ş Ç ç Ğ ğ with locale-specific behavior

Armenian [test.js:L147-L149]:

  • Tests Ե ր ե ւ ա ն

Additionally, there are tests for emoji characters like 🦄 (unicorn) and 🐶 (dog) which are handled via the customReplacements option [test.js:L101-L106].

The README also mentions support for locale-specific transliteration, including German (umlauts), Vietnamese, Arabic, Russian, and more [test.js:L214-L225].

FOLLOW_UPS:

  • How does the transliterate option affect Unicode handling?
  • What locales are specifically tested for transliteration?
  • Does the library support CJK (Chinese, Japanese, Korean) characters?

Want to ask your own question?

Open chat for sindresorhus/slugify

Public Q&A. Generated by RepoPilot from the actual source of sindresorhus/slugify. AI answers can be incomplete or stale — verify before relying on them.