[Vuejs]-Problems with Laravel 5.6 Vue.js e o app.js (404)

3👍

I found the solution for this thread

instead of using this

<script src="{{  mix('js/app.js') }}" type="text/javascript"></script>

try this

<script src="{{ asset( mix('js/app.js')) }}" type="text/javascript"></script>

-add the asset function

I hope it helps

0👍

If you use .version() in Laravel-Mix, you should use in your blade

<script src="{{ mix('js/app.js') }}"></script>

..because it’s has a versioned name instead. Same for stylesheet path:

{{ mix ('css/app.css') }}

Docs: https://laravel.com/docs/5.8/mix#versioning-and-cache-busting

👤senty

Leave a comment