Giter Site home page Giter Site logo

Comments (6)

glenjamin avatar glenjamin commented on July 20, 2024

I'm not aware of a good way to do this.

The production build would use extract text plugin to load styles early, but I don't think there's a way to do this and still have CSS in the bundle hot reloaded

from ultimate-hot-reloading-example.

donaldpipowitch avatar donaldpipowitch commented on July 20, 2024

Maybe you could use the extract text plugin for development, too, and handle reloading of CSS just with a classic livereload server.

from ultimate-hot-reloading-example.

glenjamin avatar glenjamin commented on July 20, 2024

That sounds like it could work

from ultimate-hot-reloading-example.

kale1d0code avatar kale1d0code commented on July 20, 2024

Hi don't know if you guys have come across this?
https://github.com/HumbleSpark/react-ssr-critical-styles
this should sort out above the fold css

from ultimate-hot-reloading-example.

namnm avatar namnm commented on July 20, 2024

We can achieve this using jsdom-global package. We will add global dom environment into Node. Every time we prepare html to return, we can add the style tags into that html from jsdom-global. I will make some tweaks and see if it works.

from ultimate-hot-reloading-example.

gajus avatar gajus commented on July 20, 2024

Or you could have a look at https://github.com/gajus/usus.

from ultimate-hot-reloading-example.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.