grouped
v1.0.1
Published
Lists of grouped words by type
Downloads
5
Readme
Grouped
This package is inspired by word-list
, all credits should go to the author Sindre Sorhus. Some credits should also go to the author Pass-phrase for the lists used in this package.
I wanted to create a package to be able to get word list by type which can be very helpful in certain senarios like the usage in this package : usernames
Install
$ npm install --save grouped
Usage
const fs = require('fs');
// Returns the path to the word list which is separated by `\n`
const listsPaths = require('grouped');
const verbsArray = fs.readFileSync(listsPaths.verbs, 'utf8').split('\n');
const adverbsArray = fs.readFileSync(listsPaths.adverbs, 'utf8').split('\n');
const adjArray = fs.readFileSync(listsPaths.adjectives, 'utf8').split('\n');
const nounsArray = fs.readFileSync(listsPaths.nouns, 'utf8').split('\n');
License
MIT