https://laravel.com/docs/9.x/vite#running-vite
npm run build
And set APP_URL & ASSET_URL environment correctly as well.
I am using Jetstream 2 and vite. Everything works fine locally but after placing my app on a server all the styles have stopped working.
Blade layout has this in the template
@vite(['resources/css/app.css', 'resources/js/app.js'])
Which outputs this
<script type="module" src="http://127.0.0.1:3000/@vite/client"></script>
<link rel="stylesheet" href="http://127.0.0.1:3000/resources/css/app.css" />
<script type="module" src="http://127.0.0.1:3000/resources/js/app.js"></script>
But these paths are wrong.
How do I correct them?
@joshuapphillips and you are using npm run build? And check if you have a file named hot in the public directory. If you do, delete it
Please or to participate in this conversation.