Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error shows "Failed to get text for stylesheet (#): No style sheet with given id found", what does this mean?

I'm getting this error in Chrome when it loads this application I am working on:

Failed to get text for stylesheet 50: No style sheet with given id found

Subsequent page loads repeat the error, but with a different number:

Failed to get text for stylesheet 152: No style sheet with given id found

This only happens in Chrome, and only with this application. There is no stack trace, reference, or any other information about what id is given, what the stylesheet in question is, or what is causing this generally. How can I find what is causing this error and fix it?

like image 361
Calvin Fisher Avatar asked Oct 14 '22 02:10

Calvin Fisher


People also ask

Why is my CSS style sheet not working?

Make sure the link tag is at the right place If you put the <link> tag inside another valid header tag like <title> or <script> tag, then the CSS won't work. The external style CAN be put inside the <body> tag, although it's recommended to put it in the <head> tag to load the style before the page content.

How do I enable style sheets?

Select "Preferences..." under the Edit menu. Once the Preferences dialog comes up, select the "Advanced" Category and make sure "Enable style sheets" is checked. Also make sure that you check the "Enable JavaScript" option.


1 Answers

I had the same problem. It looks like a bug in Chrome's live-edit CSS/JS. Notice how the number changes on each request.

I fixed it by closing all the files that I had edited in the dev tools 'source' tab and then refreshed the page.

The error went away after I closed all the files in the 'source' tab.

I tried to reproduce it after closing the files, but I can't seem to recreate it, yet.


Here is a picture showing where to find the 'source' tab:

enter image description here

like image 271
Taysky Avatar answered Oct 16 '22 15:10

Taysky