an-array-of-basque-words
v1.0.0
Published
List of ~4,655,000 Basque (Euskera) words
Maintainers
Readme
an-array-of-basque-words
List of ~4,655,000 Basque (Euskera) words.
Derived from the Xuxen Basque Hunspell dictionary
(eu_ES), processed and filtered to include only clean alphabetic words using the Basque character set
([a-zñ]).
Inspired by the architecture of an-array-of-english-words
by Titus Wormer.
Install
npm install an-array-of-basque-wordsUse
const words = require('an-array-of-basque-words')
console.log(words.length) // ~N words
console.log(words.slice(0, 5))
// [ 'a', 'ab', ... ]
console.log(words.filter(w => w.startsWith('eusk')))
// [ 'euskal', 'euskaldun', 'euskara', ... ]API
The default export is a string[] of Basque words.
TypeScript
Types are included:
import words = require('an-array-of-basque-words')
const filtered: string[] = words.filter(w => w.length === 5)Dataset
- Source: Xuxen Basque Hunspell dictionary
- License: GPL-2.0-or-later
- Filter: Only characters matching
/^[a-zñ]+$/
Build
To regenerate index.json from source:
node setup.js # Download eu_ES.dic and eu_ES.aff from xuxen.eus
node expand.js # Expand dictionary (memory-efficient, no external tools needed)
node build.js # Clean, filter and generate index.jsonCredits
- Linguistic data: Xuxen — Euskararen hiztegi arauemailea
- Architectural pattern: Titus Wormer (@wooorm) —
an-array-of-english-words
License
GPL-2.0-or-later © Pablo G. Guízar
