Domanda

I've done some research and can't find any way to transliterate Japanese.

Stringex would have been the best bet, but it's a known issue that it treats Japanese as Mandarin. I've verified this happens even when there are obvious Japanese characters present (ie kana). Same for Unidecoder.

I realise it's a hard problem as Kanji phonetics are ambiguous, but this is for URL slugs so it doesn't have to be perfect.

È stato utile?

Soluzione

I've never tried it, but you could try this:

https://github.com/makimoto/romaji

"Romaji" is basically the name for system the Japanese themselves use to write in Roman/Latin characters. I am not certain if transliterations targetted at romaji for Japanese speakers will be what you need if you are targetting non-Japanese speakers, but it seems like it might be good.

So you could try romaji in your google searching, that's what I did. Since ruby, of course, originated in Japan, I figured there'd be something around for it.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top