Static GitHub Issues

[2337] SSR CSS - document size becomes too large

prev: npm run generate error
next: Trying to add a mixin to main Vue instance

Nuxt by default outputs CSS loaded through the css entrypoint in nuxt.config on all pages. This is to help the page load faster by not having to make another over the wire call. However, I'm running into some major issues with the document size now.

I'm using Bulma with Buefy and some other custom css. Using the build analyzer, I can see that the gzipped size is 38kb for the entire generated css. However, because this is embedded into the html and the html is not gzipped, the size is expanded out to 375kb.

I wish 1. there is an option to gzip the html doc. With the styles added, it is 10x larger than it needs to be. Not sure what kind of performance impact it'll have on the server but would love to test out. 2. option to not add css to the html and load through linked styles. I understand this can lead to FOC but might be something I'm willing to do to avoid the large document delivery.

If someone has experience using Bulma/Buefy with Nuxt and have better optimized their load times. Please chime in and help!

<!--cmty--><!--cmty_prevent_hook--><div align="right"><sub><em>This question is available on <a href="https://nuxtjs.cmty.io">Nuxt.js</a> community (<a href="https://nuxtjs.cmty.io/nuxt/nuxt.js/issues/c2040">#c2040</a>)</em></sub></div>