You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am experiencing problems when using this library on a clean and fresh installation of GatsbyJS.
The project looks fine when it is being developed, but when a build is done and the project is executed it does not show the styles of the components.
I have created a public repository, if you can download and run the project npm run start you can see on the localhost:8000 page that the navigation bar is displayed correctly, attached screenshot.
But if you make a build and then run that build: npm run build; npm run serve you can see that the web does not load the styles, if dimensions, heights or responsive styles, I upload screenshots with my results.
But if you navigate between the two pages you will see that the styles are loaded later.
To Reproduce
Clone the repository given
Install the NPM modules running npm run ci
See the project running locally npm run start
Go to localhost:8000 on any web browser and you will be able to see the navbar styled
Stop the previous process, build and serve locally the project running npm run build; npm run serve
Go to localhost:9000 on any web browser, you will see the navbar unstyled
Use the navbar to navigate to another view, example contact and see how the navbar its styled now, even if you navigate to home again the style will still loaded.
Expected behavior
The components created with xstyled needs to keep the style even if the project its compiled for production environments
🐛 Bug Report
I am experiencing problems when using this library on a clean and fresh installation of GatsbyJS.
The project looks fine when it is being developed, but when a build is done and the project is executed it does not show the styles of the components.
I have created a public repository, if you can download and run the project
npm run start
you can see on thelocalhost:8000
page that the navigation bar is displayed correctly, attached screenshot.For more contect here is my Navbar component https://github.com/ChristianHardy/gatsby-xstyled/blob/main/src/components/Navbar/index.tsx
But if you make a build and then run that build:
npm run build; npm run serve
you can see that the web does not load the styles, if dimensions, heights or responsive styles, I upload screenshots with my results.But if you navigate between the two pages you will see that the styles are loaded later.
To Reproduce
npm run ci
npm run start
localhost:8000
on any web browser and you will be able to see the navbar stylednpm run build; npm run serve
localhost:9000
on any web browser, you will see the navbar unstyledcontact
and see how the navbar its styled now, even if you navigate tohome
again the style will still loaded.Expected behavior
The components created with xstyled needs to keep the style even if the project its compiled for production environments
Link to repl or repo (highly encouraged)
https://github.com/ChristianHardy/gatsby-xstyled
Run
npx envinfo --system --binaries --npmPackages @xstyled/system,@xstyled/styled-components,styled-components --markdown --clipboard
Paste the results here:
The text was updated successfully, but these errors were encountered: