-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
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
docs: virtual modules internal convention #5553
Conversation
@bluwy are you using virtual modules in vite-plugin-svelte? I'm going to do a PR at one point for vite core to start using |
Yeah For this case we would need to prepend that path with |
Interesting, I was thinking of the helper virtual modules (like the module preload polyfill). In the case of the modules generated from the SFCs, the file is still there, so maybe this doesn't apply (you want the sourcemap to point to the original .svelte file, no?) |
Hmm yeah putting it that way, perhaps SFCs don't need to follow the convention after all, as long as the virtual module directly derives from the single real module. Maybe it would benefit to have this in the docs too 🤔 |
@bluwy @aleclarson would you review if the added note is clear enough?
|
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.
Minor typo, but otherwise looks good to me 👍
Co-authored-by: Bjorn Lu <34116392+bluwy@users.noreply.github.com>
Description
See added docs and test
AFAICS, if plugins in the ecosystem would follow this rollup convention, then we wouldn't have dealt with issues as in #2904 and #5421
What is the purpose of this pull request?