sentry-javascript
sentry-javascript copied to clipboard
[v8] Update Next.js support policy
We currently support Next.js 10+.
In v8, we may want to raise this.
Open questions
- Do we want to raise it? How much?
@lforst can you evaluate this when you find some time?
Some facts:
- The latest Next.js@10 version was released 3 years ago and has about 10k weekly downloads (I pulled this number during Christmas week so actual is probably 3-4x). For comparison, Next.js has about 5mil downloads on regular weeks.
- The latest Next.js@11 version was released 2 years ago and has about 10k weekly downloads (also pulled this number during Christmas so actual is likely 3-4x). The most used version I can spot has about 30k/wk.
- Next.js 11 came with webpack 5 support but still supports webpack 4
- Next.js 12 removed webpack 4 support
Dropping version 10 is a no-brainer in my opinion, but we don't gain a lot from it. Dropping version 11 is a bit more debatable but would allow us to drop webpack 4 support which will allow us to simplify build time logic and drastically reduce the complexity of our test infra.
No decision yet.
Update: We may have a plan to use @vercel/otel to instrument performance in Next.js. This would require us to bump the minimum Next.js version to at least 13.
I think I have settled on this topic. Because we will rely heavily on OpenTelemetry going forward, we should use the first Next.js version that also supports OTel.
I have found the following PR in the Next.js repository: https://github.com/vercel/next.js/pull/46198, which adds some OTel instrumentation to Next.js. This change was first included in version 13.2.0 of Next.js.
Because of the above, I would vote that we make 13.2.0 the minimum version compatible with Next.js.
Sounds reasonable to me! But let's double check this with folks, to be on the safe side.
Closing because we've picked 13.2.0 as per https://github.com/getsentry/sentry-javascript/pull/11097