A Visual Studio Code extension that converts Japanese text to Romanji. This tool helps developers seamlessly translate Japanese names for methods, variables, and classes into Romanji, making code more accessible and easier to manage.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Convert Japanese text (Hiragana, Katakana and Kanji) to Romanization (Hepburn style).
Requirements
The language modes support by this extension are:
javascript
typescript
csharp
json
plaintext
ini
markdown
yaml
xml
html
css
scss
less
Usage
Select the text you want to convert and press control . (control + period) to convert the text.
Command
extension.japaneseRomanization: Transform the selected text.
extension.importCache: Import cache from a file.
extension.exportCache: Export cache to a file.
extension.clearCache: Clear cache.
extension.importDictionary: Import dictionary from a file.
extension.exportDictionary: Export dictionary to a file.
extension.clearDictionary: Clear dictionary.
extension.editDictionary: Edit dictionary.
Extension Settings
This extension contributes the following settings:
provider: Provider for convert Kanji text.
offline (default): Use the kuroshiro library to convert the text.
goo: Use the labs.goo.ne.jp API to convert the text.
OpenAI (Beta): Use the OpenAI API to convert the text and OpenAI-like endpoint.
apiKey: API key for the labs.goo.ne.jp API. (Only required if the provider is goo)
customOpenAIUrl: Custom OpenAI URL (Only required if the provider is OpenAI)
cache (default false): Cache the result of the conversion. (Faster convert for goo provider)
enableTransformMode: Enable transform mode in the suggestion list.
Known Issues
N/A
Development
yarn install
Then press F5 from visual studio code. If you get the warning: "The task 'npm: watch' cannot be tracked. Make sure to have a problem matcher defined." then click debug anyway.