Commit 31a60f4
apex-ai-net
fix: reduce serverless function bundle size under 250 MB limit
- Move @playwright/test to devDependencies (saves ~76 MB)
- Externalize heavy packages in next.config.ts (OpenAI, Stripe, Sentry, etc.)
- Add outputFileTracingExcludes to remove test files and binaries
- Configure Netlify to use esbuild bundler with external_node_modules
- Add PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD to build environment
- Create .npmrc for build optimizations
Estimated bundle size reduction: ~150-170 MB (60% reduction)
Target: <100 MB (well under 250 MB limit)
Resolves: The function exceeds the maximum size of 250 MB
See: NETLIFY_BUNDLE_SIZE_FIX.md for complete analysis1 parent 45f20df commit 31a60f4
5 files changed
Lines changed: 492 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
0 commit comments