-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
fix(next): Fix custom integrations #10220
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
Conversation
size-limit report 📦
|
99d942f to
ca1a2b9
Compare
packages/vercel-edge/src/sdk.ts
Outdated
| if (options.defaultIntegrations === undefined) { | ||
| options.defaultIntegrations = sdkDefaultIntegrations; | ||
| } | ||
| options.defaultIntegrations = |
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.
Aligning this with e.g. the node SDK - otherwise, the RequestData() integration is not added to the defaults if somebody extends this (like in nextjs).
31298a3 to
d113796
Compare
|
Tests here are failing because of #10243, once this is merged we can fix this. |
|
adding merge commit so we can include with next release |
75e43af to
4c6baed
Compare
The usage of this was not really working well to begin with, and even worse with the new functional integrations.
4c6baed to
2d1607e
Compare
The usage of this was not really working well to begin with, and even worse with the new functional integrations. Because if the user adds the integration themselves (e.g.
integrations: [new RewriteFrames()]), it will not actually get the correct iteratee at all.Overall it is much cleaner anyhow to just fork the integrations properly and use them instead of the default one - then we can rely on the standard behavior of merging integrations etc.
We need to do the same for basically all usages of
addOrUpdateIntegration, as that actually does not work at all anymore with the functional integrations 😬 (and in many instances never really worked properly if users passed in a custom integration themselves).