Add a default export for each package, matching browser#1159
Add a default export for each package, matching browser#1159mcintyre94 wants to merge 2 commits into
Conversation
🦋 Changeset detectedLatest commit: 265573a The changes in this PR will be included in the next version bump. This PR includes changesets to release 43 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
BundleMonUnchanged files (136)
No change in files bundle size Final result: ✅ View report in BundleMon website ➡️ |
|
Documentation Preview: https://kit-docs-5g6qv3m25-anza-tech.vercel.app |
lorisleiva
left a comment
There was a problem hiding this comment.
Would love Steve's opinion on this but looks good to me. Thank you!
steveluscher
left a comment
There was a problem hiding this comment.
We're super sure that ‘running the browser bundle in SSR’ solves more problems than it causes, right?
Like, what if SSR starts pulling in the browser bundle everywhere, and then something in the browser bundle tries to call AbortSignal.any() or window.localStorage.getItem() where the Node bundle would not have. The SSR will fatal, right?
|
More concretely, if the browser build was served to the Vercel Edge Runtime, this line would fatal owing to the absence of kit/packages/rpc-subscriptions/src/rpc-subscriptions-autopinger.ts Lines 54 to 56 in b80b092 Now I don't actually think you can get to that line in an SSR pass, but my point is that browser builds can fatal the SSR runtime because they presume browser APIs like this one are present. |
|
Yea I'm not convinced either. We need to document the |
|
Closing in favour of #1163 (merged) |
|
Because there has been no activity on this PR for 14 days since it was merged, it has been automatically locked. Please open a new issue if it requires a follow up. |
Problem
Good detail in the issue: #1158
TLDR: Without this, NextJS runs the Node bundle for client components in SSR, and then complains that there's no
wsSummary of Changes
Add a default export that matches the browser export for each public package
Fixes #1158