Oct 14, 2023
0
Level 1
Unable to locate file in Vite manifest: resources/css/app.css MANIFEST PATH ERROR
Hello, im using a blade.php file that uses @vite('resources/css/app.css') for tailwind implementation, this page renders perfectly on local env, but when i build for production and run it on the website i get the following error
Unable to locate file in Vite manifest: resources/css/app.css. (View: /PAGEPATH/FILENAME.blade.php)
The error comes from the manifest.json, which wrongly sets the path for app.css
"resources/js/app.css": { //should be "resources/css/app.css"
"file": "assets/app.dba4a831.css",
"src": "resources/js/app.css" //should be "src":"resources/css/app.css"
},
Changing the paths fixes the problem.
Everytime i run npm run build it wrongly sets up the path, im using "vite": "^3.0.4", is there anything i can do besides manually editing the path everytime i run for production? Any help is appreciated!
Please or to participate in this conversation.