1.0.1 • Published 3 years ago
@reliutg/spellchecker-js v1.0.1
🌎 spellchecker-js
Tool for check for spelling errors (zh-CN, zh-TW, en, es)
Install
npm install @reliutg/spellchecker-js
Example
const { SpellChecker } = require("@reliutg/spellchecker-js");
const spell = new SpellChecker();
// Load dictionary
spell
.load({
lang: "es",
})
.then(() => {
const check = spell.check("acné aaaa"); // returns words with mistakes in the text
console.log(check);
});
// Output: ["aaaa"]
Supported languages
- zh-CN: Chinese (Simplified)
- zh-TW: Chinese (Traditional)
- en: English
- es: Spanish