solidjs / solid-start

SolidStart, the Solid app framework
https://start.solidjs.com
MIT License
5.18k stars 375 forks source link

Duplicate CSS with tailwind #298

Closed ghost closed 10 months ago

ghost commented 2 years ago

When using solid-start with tailwind, it creates multiple instances of the generated css styles.

image These two contains identical css

It seems to also include more duplication from the pages image

arekbartnik commented 1 year ago

@JonahLund was this issue resolved for you? I can see this duplication of style in the with-tailwindcss template.

quantuminformation commented 1 year ago

we get the same

image
ghost commented 1 year ago

@JonahLund was this issue resolved for you? I can see this duplication of style in the with-tailwindcss template.

No this was never resolved, but this only occurs in development so i figured that its probably not urgent enough to have an active issue regarding it

arekbartnik commented 1 year ago

@JonahLund would you reopen it? it is "dev" only issue but it makes debugging styles harder

arekbartnik commented 1 year ago

this problem is caused by https://github.com/solidjs/solid-start/commit/b83372e2b5095d1a0c2e40f861cf6b237970833f <InlineStyles />is included in dev and then vite inserts its own inline styles.

i think it's better to ignore/live with FOUC then fight with duplicated styles in devtools.

ghost commented 1 year ago

agreed, duplicated styles are problematic for larger tailwindcss applications, it severly degrades performance when all styles are duplicated 2 or three times and makes inspecting/debugging extremely annoying when developing

ryansolid commented 1 year ago

Hmm.. the FOUC was a big deal. Lots of complaints. People confused thinking Start was broken. I was told it was near unusable. Now I don't have such hard opinions here, but I can't understate the complaining.

ryansolid commented 10 months ago

In setting up for SolidStarts next Beta Phase built on Nitro and Vinxi we are closing all PRs/Issues that will not be merged due to the system changing. If you feel your issue was closed in mistake. Feel free to re-open it after updating/testing against 0.4.x release. Thank you for your patience.

See https://github.com/solidjs/solid-start/pull/1139 for more details.