-
-
Notifications
You must be signed in to change notification settings - Fork 38
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
perf(netlify): handle dependency tracing for SSR function #296
Conversation
🦋 Changeset detectedLatest commit: f5fa01e The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 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 |
Invalid command. Expected: "/preview " |
!preview netlify-nft |
Snapshots have been released for the following packages:
Publish Log
Build Log
|
!preview netlify-nft |
Snapshots have been released for the following packages:
Publish Log
Build Log
|
WINDOWS PATHS 😱 |
Changes
Currently this adapter relies on the Netlify build process to bundle and trace the SSR functions. This can be slow, particularly when there are a large number of generated chunks from content collections. This PR changes the adapter to handle its own tracing using
@vercel/nft
. This is already done in the@astrojs/vercel
, so I've mostly taken the code from there and adapted it a bit. Once we've done that we can tell Netlify to not bundle the generated function. For context, the astro.build site was taking over 6 minutes to bundle before this. With this PR, the bundling takes 6 secondsSee https://app.netlify.com/teams/ascorbic/builds/667d304a908d450008617d30 for an example build
Testing
Docs