/wanikani-vocab-beyond

WaniKani userscript to display WWWJDIC words and Forvo audio for Japanese vocabulary

Primary LanguageTypeScriptMIT LicenseMIT

WaniKani Vocab Beyond

WaniKani Vocab Beyond

Description

This WaniKani script lets you study much more vocabulary for each kanji than is included in WaniKani, by showing hiragana pronunciation, definitions, part of speech, and commonality indicators for vocabulary retrieved from Jim Breen's WWWJDIC API. It also allows you to listen to any native speaker pronunciations from Forvo for each vocabulary word (if you pay $24/year for a Forvo API key), and allows you to filter audio by Forvo username (and thus filter by regional dialects).

The Vocab Beyond section is rendered on kanji lessons, kanji reviews, and kanji pages.

Vocab Beyond will still show WWWJDIC vocab, even if you don't configure it with a valid Forvo API key.

Requirements

Installation

  1. Install @rfindley 's WaniKani Open Framework according to these instructions.
  2. Install this script from Greasyfork at https://greasyfork.org/en/scripts/372737-wanikani-vocab-beyond
  3. (Optional) Configure Vocab Beyond with your Forvo API key.
    1. Sign up for a Forvo account at https://forvo.com/signup/
    2. Purchase a Fovo API key at https://api.forvo.com/plans-and-pricing/
    3. Copy your Forvo API key from https://api.forvo.com/account/
    4. Open the Vocab Beyond settings from the menu at the top right of your WaniKani dashboard: Settings accessed from dashboard
    5. Paste your API key into the field under the Audio settings tab: Forvo API key field

Settings

This section explains any settings options that aren't entirely self-explanatory.

Audio Settings

Audio settings

Vocab Settings

Each non-profit tier Forvo API key is limited to 500 API requests per day. To avoid hitting your quota, you can limit the maximum number of WWWJDIC vocabulary words to query the Forvo API with, using vocab settings in this tab:

Vocab settings

Appearance Settings

Appearance settings

Show Vocab Beyond first

By default, Vocab Beyond is rendered in:

  • Kanji lessons: In the last "Examples" tab

  • Kanji reviews: At the bottom of the expanded Item Info section

  • Kanji pages: After the "Found in Vocabulary" section

By checking Show Vocab Beyond first, the Vocab Beyond section will be rendered first, so you can see it as soon as possible:

  • Kanji lessons: In the first "Radicals" tab

  • Kanji reviews: At the top of the expanded Item Info section

  • Kanji pages: At the top of the page

Hide uncommon icon

If you have enabled the "Show uncommon vocab" checkbox in the Vocab settings tab, you'll see orange circular icons beside uncommon vocabulary.

  • With the uncommon vocab indicator icon visible

  • With the uncommon vocab indicator icon hidden

Support

Post a comment at https://community.wanikani.com/t/userscript-wanikani-vocab-beyond/33046 or open a GitHub Issue at https://github.com/normful/wanikani-vocab-beyond

Contributing

You can build the script locally by installing yarn and building with webpack:

git clone git@github.com:normful/wanikani-vocab-beyond.git
cd wanikani-vocab-beyond
brew install yarn
yarn
yarn build

Development commands:

  • yarn build runs webpack once
  • yarn watch runs webpack and watches for changes
  • yarn lint runs TSLint on all TypeScript files
  • yarn prettier runs Prettier on all TypeScript files
  • yarn test runs Jest tests once
  • yarn testwatch runs Jest tests and watches for changes

In development, you might also want to:

Publishing

(Notes to self): For releasing a new version:

https://greasyfork.org/en/scripts/372737-wanikani-vocab-beyond/admin is already configured to pull from GitHub, but you can press the Update and sync now button if you're impatient.

Credits

Thanks @rfindley and @axetroy for the following projects that this script heavily relies on: