DevTools failed to parse SourceMap error after login will redirect to that js file

If you use Laravel Mix, you can generate source maps by calling the mix.sourceMaps() method in your webpack.mix.js file. This resolves the problem.

mix.js('resources/js/app.js', 'public/js').sourceMaps();

Laravel Mix Source Maps documentation


I found that one solution is created a dummy file at public/js/popper.js.map, then it will back to normal, basically just fulfil what browser developer tool required, it will not redirect to that specific file.

I believe this is browser developer tools behaviour.

I received solution from the laraStart repo owner.

This error happens when you have an error and compile your javascript code. Later, when you fix it, it will remain in cache and happens. Please try to compile your script again and login to see.

The solution is also working as well.

I run npm update and npm run dev, it is working fine.


Open "find in files", find every commented line of code that has

sourceMappingURL=...

Delete the whole commented line for each.

There should be 3 entries here in public/app.js and 1 at the end of popper.js.

If you are using Brave shields or an ad blocker, turn it off

Tags:

Laravel

Vue.Js