ravenberg / laravel-inertia-react-preset
An Inertia.js + Reactjs preset for the Laravel Framework
Installs: 32
Dependents: 0
Suggesters: 0
Security: 0
Stars: 10
Watchers: 2
Forks: 1
Open Issues: 0
Language:JavaScript
Requires
- php: ^7.3
- illuminate/console: ~5.8|^6.0
- illuminate/filesystem: ~5.8|^6.0
- illuminate/support: ~5.8|^6.0
- inertiajs/inertia-laravel: ^0.1
- laravel/ui: ^1.0
Requires (Dev)
- mockery/mockery: ^1.2
- phpunit/phpunit: ^8.0
This package is auto-updated.
Last update: 2024-05-14 19:42:01 UTC
README
Leverage ReactJS as your view layer within your Laravel application. This is a preset to setup Inertia + React within a fresh Laravel installation. By using this, you get front-end scaffolding including authentication. Tailwind is setup as well.
The benefit of using Inertia is how you are able to use Laravel and all its beloved features while having a modern front-end along with that modern front-end development workflow;
$ npm run hot
A proxy server is started with hot reloading. If you are not using Laravel Valet you may have to change the proxy url within your webpack.mix.js file.
Setup
Follow these 3 steps to execute the scaffolding using this preset.
Step 1
Assuming a fresh laravel installation, run the following command to get started;
$ composer require --dev ravenberg/laravel-inertia-react-preset
Step 2
Run the actual command
$ php artisan ui:auth inertia-react
Step 3
Pull in dependencies and run a build
$ npm install && npm run dev
🎉 You're all set. Time to craft your app.