Skip to content
This repository has been archived by the owner on Jul 27, 2019. It is now read-only.
/ romaji2kana Public archive

This package exposes a function for converting romaji strings into kana.

License

Notifications You must be signed in to change notification settings

kinbiko/romaji2kana

Repository files navigation

Romaji2Kana

Build Status Go Report Card Coverage Status Latest version Go Documentation License

This repository is now deprecated in favour of nihon-go, which contains a function to achieve the same behaviour, and more.

This package exposes a ToKana function for converting romaji strings into kana.

Restrictions

This package was written in order to allow myself to write quick notes without switching keyboard layout when taking notes (but rather process these later). Therefore, there's very little 'intelligence' in this package. For example, there's no grammatical inference of whether 'wa' is「は」or 「わ」.

Moreover the form in which the kana should be written is very strict. In particular, only the following form is supported:

toukyou - とうきょう

The following romanization forms will not work as one might expect:

tōkyō - error
tokyo - ときょ
tohkyoh - error
tookyoo - とおきょお

The package expects hiragana to be all lower case and katakana to be all upper case.

Toukyou - error
TOUKYOU - トーキョー

Usage

See the official documentation on godoc for usage.