Download the PHP package modstore/laravel-enum-js without Composer
On this page you can find all versions of the php package modstore/laravel-enum-js. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download modstore/laravel-enum-js
More information about modstore/laravel-enum-js
Files in modstore/laravel-enum-js
Package laravel-enum-js
Short Description Package to generate javascript versions of your PHP enum files to be used in your js builds etc.
License MIT
Homepage https://github.com/modstore/laravel-enum-js
Informations about the package laravel-enum-js
Laravel Enum Js
Package to generate javascript versions of your PHP enum files to be used in your js builds etc. Works with Php8.1+ enums, constants in your PHP files, or you can use a package such as https://github.com/BenSampo/laravel-enum
Installation
You can install the package via composer:
Publish the config:
Usage
Create a storage location, the path the generated files will be saved to.
Check the other configuration options in the config file.
You can generate the js files by running the following Artisan command:
NOTE: When developing, if you create a new file, you will likely need to dump the autoload files before this command will pick it up, e.g.
You can then use the generated files in your javascript like so:
Testing
Changelog
Please see CHANGELOG for more information what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Credits
- Mark Whitney
- All Contributors
License
The MIT License (MIT). Please see License File for more information.