A PHP library containing word lists for various categories and languages. This library is generated from the cool-studio/words repository.
You can install the package via composer:
composer require words-studio/words-phpuse Words\EN\Animals;
// Get all words
$allAnimals = Animals::words();use Words\EN\Animals;
// Get a random word
$randomAnimal = Animals::word();The library includes the following word lists:
- Animals
- SciFi
- Space
- Tech
- Words (General words)
Word lists are generated from the cool-studio/words repository. To update the word lists or generate new ones:
- Make sure you have Node.js installed
- Run the generation script:
node generate.jsThis will:
- Clone or update the words repository
- Generate PHP classes for each word list
- Update the version in composer.json
This project is licensed under the MIT License - see the LICENSE file for details.