Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Caching with layout.css and <Layout>? #14163
I'm seeing layout.css referenced after starting a new site with gatsby when using
Steps to reproduce
Then, stop dev server.
Replace ./pages/index.js with the below...
Then run the dev server
View site in browser.
Note the H1 is using the
Open up the developer tools to check things out...
Not sure why the reference to layout.css style exists. With the update to index.js I removed the component which is the source of the reference to
I thought, maybe caching, so I opened up incognito and no luck.
Then I tried up Safari (was using Chrome prior)... but the same result.
Next, stop dev server and then...
Viewed the site again, but the issue still exists.
Next, stop dev server.
Let's try something else... let's build the static site and view the results versus using
My assumption is when I remove the component from the index.js file that the result would remove the reference to layout.css which it does do correctly in
It appears layout.css is cached.
If I remove the "Layout" component from all page JS files (404, index, page-2) then the issue is resolved. Not sure if this should stay open or not but I created the ticket as I thought someone else may run into this and wanted to share. This isn't a roadblock for me, but possibly a confusion for someone getting started with gatsby?
This issue has gone quiet. Spooky quiet.
We get a lot of issues, so we currently close issues after 30 days of inactivity. It’s been at least 20 days since the last update here.
If we missed this issue or if you want to keep it open, please reply here. You can also add the label "not stale" to keep this issue open!
As a friendly reminder: the best way to see this issue, or any other, fixed is to open a Pull Request. Check out gatsby.dev/contributefor more information about opening PRs, triaging issues, and contributing!
Thanks for being a part of the Gatsby community!
It’s been 30 days since anything happened on this issue, so our friendly neighborhood robot (that’s me!) is going to close it.
Please keep in mind that I’m only a robot, so if I’ve closed this issue in error, I’m
As a friendly reminder: the best way to see this issue, or any other, fixed is to open a Pull Request. Check out gatsby.dev/contribute for more information about opening PRs, triaging issues, and contributing!
Thanks again for being part of the Gatsby community!