Skip to content
The most popular spellchecking library. (converted to js using emscripten)
Branch: master
Clone or download
Pull request Compare This branch is 2 commits ahead, 1 commit behind hunspell:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
js-output
m4
man
msvc
po
scripts
src
tests
.gitignore
.travis.yml
ABOUT-NLS
AUTHORS
COPYING
COPYING.LESSER
COPYING.MPL
ChangeLog
ChangeLog.O
Makefile.am
NEWS
README
README.md
THANKS
appveyor.yml
config.rpath
configure.ac
hunspell.pc.in
license.hunspell
license.myspell

README.md

Hunspell js

This is js library ported from Hunspell (c++)[https://github.com/hunspell/hunspell] using emscripten

Running Example

  • Goto js-output folder, and run a http server (for example using python: python -m SimpleHTTPServer 8080)
  • Open http://localhost:8080/ in browser
  • Current dictionary using is en-us, you can change to use another dictionary by modifing index.html:
    • change <script type="text/javascript" src="loader-en-us.js"></script> to <script type="text/javascript" src="loader-vi.js"></script>
    • it will change from en-us to vi
    • Example script now only preload with 2 dictionaries, if you want to add your own, please refer below section

How to build hunspell js from hunspell C++ manually, instruction based on MACOS only

How to build your own dictionaries

This repo only have to dictionaries (en-us and vi), to build your own dictionaries to use, following steps:

  • Download your dictionaries and put into dics-input folder in format:
    • [language-code]/data.aff
    • [language-code]/data.dic
  • Run ./scripts/dic-package.sh [path-of-file_packager.py]

Dictionaries

Hunspell (MySpell) dictionaries:

Aspell dictionaries (conversion: man 5 hunspell):

  • ftp://ftp.gnu.org/gnu/aspell/dict
You can’t perform that action at this time.