vite icon indicating copy to clipboard operation
vite copied to clipboard

CSS with media and disabled prop not processed

Open bluwy opened this issue 3 years ago • 0 comments

Describe the bug

CSS linked via <link rel="stylesheet" href="./bla.css" media="screen" /> is not processed by default after #6751. I think it's still good as we provide a way for this to work with the caveat that PostCSS won't process them.

This issue is to track progress on processing these CSS files.

I've looked into it, and it seems harder than expected, since we need to pass the attribute info to chunk.viteMetadata.importedCss to properly re-generate the links. Currently it's only a list of strings, which isn't enough without making a breaking change, since it's public API.

Reproduction

https://stackblitz.com/edit/vitejs-vite-7sqny9?terminal=dev

System Info

Stackblitz

Used Package Manager

npm

Logs

No response

Validations

bluwy avatar Jul 28 '22 07:07 bluwy