inertiajs.com
inertiajs.com copied to clipboard
Add instructions for Laravel Vite
As Laravel 9.x onwards, vite has replaced mix as the default asset bundler. Setting up instructions on how to setup a new Laravel Inertia project from scratch would be incredibly helpful for people who do not want to start with templates.
I'm also interested in working on this but I want to know how this project wants to implement this first. Thank you.
Yes I keep setting up new projects only to find a blank screen until I found out I should replace
<link href="{{ mix('/css/app.css') }}" rel="stylesheet" />
<script src="{{ mix('/js/app.js') }}" defer></script>
With
@vite('resources/js/app.js')
@vite('resources/css/app.css')
@MarkSemaan are you using .js extension on your project? can you share how you setup your app.js as I am having error build on it