Latinize
Simple library to convert accents (diacritics) from strings to latin characters.
Install / Use
/learn @dundalek/LatinizeREADME
Latinize.js [deprecated]
! This library is deprecated !
As an alternative you can user the transliterate package instead.
Simple library to convert accents (diacritics) from strings to latin characters.
Install
npm install latinize
For CommonJS module format use the 1.x version
npm install latinize@1
Usage
ES module
import latinize from 'latinize';
latinize('ỆᶍǍᶆṔƚÉ áéíóúýčďěňřšťžů'); // => 'ExAmPlE aeiouycdenrstzu'
You can use the latinize.characters object to access the translation table and pass custom mapping as a second argument:
// modify the behavior for German umlauts
const characters = {
...latinize.characters,
'Ä': 'Ae', 'Ö': 'Oe', 'Ü': 'Ue', 'ä': 'ae', 'ö': 'oe', 'ü': 'ue'
};
latinize('ÄÖ', characters) // => "AeOe"
Details
Is is a lookup table taken from http://jsperf.com/latinize packaged for node and browser. Visit the link to see more approaches.
Related Skills
node-connect
339.1kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
83.8kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
339.1kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
commit-push-pr
83.8kCommit, push, and open a PR
