Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Chrome not loading CSS source maps?

Until recently, my Chrome browser was loading CSS source map files correctly. Now, it is not.

The setting is on:

enter image description here

And the CSS files have a source mapping tag at the bottom:

/*# sourceMappingURL=Home.cshtml.css.map */

But the Network tab and Fiddler2 show that Chrome is not even trying to load the source map file.

Is there something that I'm missing? Is the sourceMappingURL syntax correct? I've toggled the "Enable CSS source maps" setting on and off.

Chrome version: 44.0.2403.30 beta-m

Sourcemap files generated by Web Essentials in VS 2013.

like image 768
Glen Little Avatar asked Sep 08 '25 19:09

Glen Little


2 Answers

You can try the following steps:

1- delete the map file and regenerate it again.

2- Using the chrome inspector, go to Settings > General and then click on the button "Restore defaults and reload"

like image 153
alaahd Avatar answered Sep 10 '25 09:09

alaahd


When the CSS file has the sourcemapping embedded as base64, then it seems to work fine.

For example:

/*# sourceMappingURL=data:application/json;base64,eyJ2....5235== */
like image 31
Glen Little Avatar answered Sep 10 '25 07:09

Glen Little