-
-
Notifications
You must be signed in to change notification settings - Fork 4.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
chore: directly export function in non-HMR mode #11333
Conversation
|
program.body[0].leadingComments = [ | ||
{ | ||
type: 'Line', | ||
value: ` ${basename} (Svelte v${VERSION})` |
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.
I think this should stay if discloseVersion
is true
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.
why? feels like a semantic overload. i'm not sure the comment has much value
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.
I don't know, historical reasons I guess - Svelte always had a comment about it at the top historically. But I realize that's a silly argument and the actual discloseVersion probably does a better job at communicating the version, so I'm ok with it now.
Co-authored-by: Simon H <5968653+dummdidumm@users.noreply.github.com>
I was wondering why the extra assignment and not simply |
That would be ideal but it would involve jumping through a bunch of extra hoops — I haven't tried it, but I would expect it to add a fair chunk of complexity. Minifiers will take care of it, so at the very least we're not adding overhead to prod bundles |
this is vain, but it'd be cool if the 'JS output' tab had as little noise as possible. Right now a
<h1>Hello world!</h1>
component yields this:Between this PR and #11319, it becomes this: