Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CSS Mismatch in Gatsby develop version and Gatsby build version in Netlify and also local #13161

Closed
progpopper opened this issue Apr 5, 2019 · 2 comments

Comments

@progpopper
Copy link

##This is a similar issue related to #5734

I tried everything discussed in the section, deleting the cache, node_modules, then did npm install and did run npm run build

It didn't work for me

My dependencies in package.json file

"dependencies": {
"@fortawesome/fontawesome-svg-core": "^1.2.17",
"@fortawesome/free-brands-svg-icons": "^5.8.1",
"@fortawesome/free-solid-svg-icons": "^5.8.1",
"@fortawesome/react-fontawesome": "^0.1.4",
"gatsby": "^2.3.5",
"gatsby-image": "^2.0.37",
"gatsby-plugin-manifest": "^2.0.26",
"gatsby-plugin-offline": "^2.0.25",
"gatsby-plugin-react-helmet": "^3.0.11",
"gatsby-plugin-sharp": "^2.0.32",
"gatsby-plugin-styled-components": "^3.0.7",
"gatsby-source-contentful": "^2.0.45",
"gatsby-source-filesystem": "^2.0.28",
"gatsby-transformer-remark": "^2.3.8",
"gatsby-transformer-sharp": "^2.1.17",
"prop-types": "^15.7.2",
"react": "^16.8.6",
"react-dom": "^16.8.6",
"react-helmet": "^5.2.0",
"styled-components": "^4.2.0",
"typeface-poppins": "0.0.72"
},

Inferences

  • A style sheet is generating after the build, but seems like it is not getting reflected (styles.xxxxxx.css)

  • Whatever styles that are given internally inside a component is reflected

  • I have put all the global css in layout.css, which is not getting reflected

Expected result

The same version of develop is expected to produce after the final build

Actual result

layout css not reflecting..

Code

You can find my code in my repo here

Thanks in advance for help.

@progpopper
Copy link
Author

it was because of gatsby-styled-components plugin was not installed

@wuyuandi
Copy link

wuyuandi commented May 6, 2020

i have the same issue with u, after add up gatsby-styled-components in config, gatsby build works

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants