inputlogic / pwa-starter

A starting point for Preact based PWAs (WIP)
MIT License
3 stars 0 forks source link

CSS Broken Sometimes #89

Closed adriaanwm closed 4 years ago

adriaanwm commented 4 years ago

Sometimes css breaks on npm start, this has happened to both Cory and I. This wasn't too big a deal since we could just start again and eventually it works. Unfortunately it just happened on staging, so now I think it's something that needs fixing.

adriaanwm commented 4 years ago

This happened again, so I inspected CSS. It looks like for some reason the reset css is being assigned after our custom styling (so in inspect it was at the very top).

Maybe importing less into js is not resulting in reliable css order?

staydecent commented 4 years ago

Yeah the LESS bundling is pretty hacked in. We should look for a more official plugin for rollup. I miss brunches enforced ordering of assets :(

I'd like to move to parcel or another bundler that works with less configuration. But, I'll look for a quicker fix for now.

staydecent commented 4 years ago

Relevant issue: https://github.com/thgh/rollup-plugin-css-only/issues/16

Currently fixed in this fork: https://github.com/staydecent/rollup-plugin-css-only

And waiting on PR to be upstreamed: thgh/rollup-plugin-css-only#21

staydecent commented 4 years ago

man, getting this on every build on netlify...