toKana() seems to not allow combinations んや んゆ んよ
Tommi377 opened this issue · 2 comments
Tommi377 commented
Issue Type
Description
The current behaviour is:
String: nnya, ToKana: んにゃ
String: nnyo, ToKana: んにょ
String: nnyu, ToKana: んにゅ
On the Google IME expected behaviour is:
String: nnya, ToKana: んや
String: nnyo, ToKana: んよ
String: nnyu, ToKana: んゆ
There doesn't seem to be a way to generate those kanas with the ToKana method
Steps to reproduce
Use the ToKana method in node and type nny + (a or o or u)
Versions
- Browser: node v10.14.2
- OS/Device: Windows 10
- Keyboard/Input Method: romaji
Tommi377 commented
fixed this by adding { customKanaMapping: { nn: 'ん' }}. Shouldn't this be default behaviour?
esnaultdev commented
I think that you're looking for toKana(input, { IMEMode: true})
.
As documented here, IME mode is turned off by default and needs to be activated to match your expectations.