-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Regression: can not get css text in the plugin #3610
Comments
)" fix for vitejs#3610 and partial fix for vitejs#2282 This reverts commit 65d333d
@patak-js , @anncwb : I see based on #2148 (comment) and #2148 (comment) that this was already in discussion at #2148. Should the solution for both problems be followed up in that ticket? |
@ferdinando-ferreira I was planning to comment in #3402 about this. As you said, the solution should be one of the possibilities described in #2148 so users that want to access the CSS string to handle it themselves can still do it (and in that case, it will not be auto-applied). The last time we discussed this with Evan, there was still uncertainty about the API though. The API should also take into account proposals that may allow us to do this natively on the web (although it may end up looking similar to https://github.com/tc39/proposal-import-assertions). If you have a proposal to share, you could do it in that issue or you could draft a PR implementing it forking the one that was reverted. We can then discuss these options again with Evan. |
This issue has been locked since it has been closed for more than 14 days. If you have found a concrete bug or regression related to it, please open a new bug report with a reproduction against the latest Vite version. If you have any other comments you should join the chat at Vite Land or create a new discussion. |
Describe the bug
After upgrading to 2.3.4, the custom plugin can’t get the css value.
This is caused by #3402, I am not sure why the output is changed to an empty string, which is useful for some specific css processing plugins.
For example, a plugin that extracts the color of certain variables in the entire css
Reproduction
System Info
Output of
npx envinfo --system --npmPackages vite,@vitejs/plugin-vue --binaries --browsers
:Used package manager:
Logs
Before submitting the issue, please make sure you do the following
The text was updated successfully, but these errors were encountered: