dictionary-lv
Version:
Latvian spelling dictionary
132 lines (85 loc) • 2.98 kB
Markdown
# dictionary-lv
Latvian spelling dictionary.
## Contents
* [What is this?](#what-is-this)
* [When should I use this?](#when-should-i-use-this)
* [Install](#install)
* [Use](#use)
* [API](#api)
* [`Dictionary`](#dictionary)
* [Examples](#examples)
* [Compatibility](#compatibility)
* [Security](#security)
* [Contribute](#contribute)
* [License](#license)
## What is this?
This is a Latvian dictionary,
generated by [`wooorm/dictionaries`][github-dictionaries] from
[`dict.dv.lv`][source],
normalized and packaged so that it can be installed and used like other
dictionaries.
## When should I use this?
You can use this package when integrating with tools that perform spell checking
(such as [`nodehun`][github-nodehun] or [`nspell`][github-nspell]) or when
making such tools.
## Install
This package is [ESM only][github-gist-esm].
In Node.js (version 16+),
install with [npm][npm-install]:
```sh
npm install dictionary-lv
```
## Use
```js
import lv from 'dictionary-lv'
console.log(lv)
// To do: use `lv` somehow
```
Yields:
```js
{aff: <Buffer>, dic: <Buffer>}
```
## API
This package exports no identifiers.
The default export is a [`Dictionary`][api-dictionary].
It exports the [TypeScript][] type
[`Dictionary`][api-dictionary].
### `Dictionary`
[Hunspell][] dictionary.
###### Fields
* `aff` ([`Buffer`][node-buffer])
— data for the affix file (defines the language, keyboard, flags, and more)
* `dic` ([`Buffer`][node-buffer])
— data for the dictionary file (contains words and flags applying to those
words)
## Examples
See the [monorepo readme][github-dictionaries] for examples.
## Compatibility
This projects is compatible with maintained versions of Node.js.
When we cut a new major release,
we drop support for unmaintained versions of Node.
This means we try to keep the current release line,
compatible with Node.js 12.
## Security
This package is safe.
## Contribute
See the [monorepo readme][github-dictionaries] for how to contribute.
> 👉 **Note**: dictionaries are not maintained here.
> Report spelling problems upstream
> ([`dict.dv.lv`][source]).
## License
Dictionary and affix file:
[LGPL-2.1](https://github.com/wooorm/dictionaries/blob/main/dictionaries/lv/license).
Rest: [MIT][file-license] © [Titus Wormer][wooorm].
[api-dictionary]: #dictionary
[file-license]: https://github.com/wooorm/dictionaries/blob/main/license
[github-dictionaries]: https://github.com/wooorm/dictionaries
[github-gist-esm]: https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c
[github-nodehun]: https://github.com/nathanjsweet/nodehun
[github-nspell]: https://github.com/wooorm/nspell
[hunspell]: https://hunspell.github.io
[node-buffer]: https://nodejs.org/api/buffer.html#buffer_buffer
[npm-install]: https://docs.npmjs.com/cli/install
[source]: http://dict.dv.lv/home.php?prj=lv
[typescript]: https://www.typescriptlang.org
[wooorm]: https://wooorm.com