marco-prontera / vite-plugin-css-injected-by-js

A Vite plugin that takes the CSS and adds it to the page through the JS. For those who want a single JS file.
MIT License
429 stars 26 forks source link

umd.js file still does not include css when use vite build --watch #144

Closed wangmerry closed 2 months ago

wangmerry commented 6 months ago

💉 Failing Test

Which jobs/test(s) are failing

*


Reason for failure/description


Media prove


Additional context

*

wangmerry commented 6 months ago

vite. formats: ['es', 'umd'],

waelbettayeb commented 3 months ago

I can confirm that it's not working on watch mode when there's multiple format

marco-prontera commented 2 months ago

When using the --watch option the build run in a different manner, and I think this is a bug of Vite.js since the purpose of the --watch is only to have the "autoupdate". I tried to fix this, but the css file is compiled only for one step and this is random, so this means that I can't get this thing in the building process. Maybe you can open an issue to the Vite project for that.