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
[feat] Compiler option css: 'none' support #7914
Conversation
@benmccann Thanks for the advice. It should be fine now. Let me know if you need anything else from me. |
@maxiruani it looks like this PR needs a rebase |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. But I think we need to update the document.
https://svelte.dev/docs#compile-time-svelte-compile
Hi @benmccann, sorry for the delay, I've been on vacations. Does the PR still needs a rebase? |
Yes, this PR still needs to be updated. You can see that it says "This branch has conflicts that must be resolved". And the docs should be updated as @baseballyama suggested |
@benmccann I think it should be fine now. Sorry for the trouble |
Why?
I found that generating client side hydratable code with
css: false
orcss: true
end up processing styles entirely unnecessary.When hydrating SSR components, the styles are commonly already generated and there is no need to generate it again for the client side bundle.
This will speed up the build development process because it completely avoids processing it.
Details
'injected'
(formerlytrue
) and'external'
(formerlyfalse
) css option values. It still supports boolean values but it raises deprecated warning.'none'
css option.css: 'none'
option.References
css: 'none'
support #7890 Old corrupted PR.css
option #7270 rename compilercss
optionBefore submitting the PR, please make sure you do the following
[feat]
,[fix]
,[chore]
, or[docs]
.Tests
npm test
and lint the project withnpm run lint