- 12 Nov, 2025 1 commit
-
-
nextjs-bot authored
-
- 11 Nov, 2025 1 commit
-
-
nextjs-bot authored
-
- 28 Oct, 2025 14 commits
-
-
nextjs-bot authored
-
nextjs-bot authored
-
nextjs-bot authored
-
Sebastian "Sebbie" Silbermann authored
-
Niklas Mischkulnig authored
The `.contains("/node_modules/")` condition didn't work for npm, where the path might be `"node_modules/.prisma/client"` This fixes cases of the following error with Prisma and npm ``` Prisma Client could not locate the Query Engine for runtime "rhel-openssl-3.0.x". We detected that you are using Next.js, learn how to fix this: https://pris.ly/d/engine-not-found-nextjs. This is likely caused by tooling that has not copied "libquery_engine-rhel-openssl-3.0.x.so.node" to the deployment folder. Ensure that you ran `prisma generate` and that "libquery_engine-rhel-openssl-3.0.x.so.node" has been copied to "node_modules/.prisma/client". We would appreciate if you could take the time to share some information with us. Please help us by answering a few questions: https://pris.ly/engine-not-found-tooling-investigation The following locations have been searched: /var/task/node_modules/.prisma/client /var/task/node_modules/@prisma/client /vercel/path0/node_modules/@prisma/client /tmp/prisma-engines ``` -
Sebastian "Sebbie" Silbermann authored
-
Jiwon Choi authored
Proxy is not being picked up during prod on Windows. It is because of two reasons: 1. `isAtConventionLevel` condition was false as the dir was `\\` in Windows, but was checking with explicit `/`. 2. `page` value passed to `getStaticInfoIncludingLayouts` function was in `\\proxy` but was expected to be `/proxy`, which is later used for `isProxy` condition. Therefore, the given paths needed to be normalized. Current behavior: https://github.com/vercel/next.js/actions/runs/18872127141/job/53853048061?pr=85443#step:34:160 Closes NEXT-4756
-
Sebastian "Sebbie" Silbermann authored
[test] Exclude likely Next.js internal Components from component stacks in Redbox assertions (#85420)
-
Alessandro Grosselle authored
### What? - Upgrade development dependency **Express** to the latest version (5.1.0). - Replace direct assignment of `apiReq.query` with `Object.defineProperty` to ensure the property is writable, enumerable, and configurable. ### Why? - To use the most up-to-date and supported version of Express instead of a legacy one. - To fix [expressjs/express#6633](https://github.com/expressjs/express/issues/6633), where Express 5.x defines `req.query` as a read-only getter, preventing Next.js from overriding it directly. ### How? - Update the Express version in `package.json` and run `pnpm install` to apply the change. - Replace: ```js apiReq.query = query; ``` With ```js Object.defineProperty(apiReq, 'query', { value: { ...query }, writable: true, enumerable: true, configurable: true, }); ``` --------- Co-authored-by:
Alessandro Grosselle <alessandro.grosselle@adevinta.com> Co-authored-by:
graphite-app[bot] <96075541+graphite-app[bot]@users.noreply.github.com> Co-authored-by:
Sebastian Beltran <bjohansebas@gmail.com> Co-authored-by:
Tim Neutkens <tim@timneutkens.nl>
-
Sebastian "Sebbie" Silbermann authored
[test] Exclude Next.js internal stack frames from cache-component-error CLI output assertions (#85421)
-
Andrew Clark authored
This is a stack of refactors related to the internal map type used to store Segment Cache entries on the client. Refer to each commit message for full details. The main motivation is to generalize the "fallback entry" mechanism used for interception routes to more kinds of params. Currently this is only used for interception routes and search params, but in the future we will use it for route params, too.
-
Sebastian "Sebbie" Silbermann authored
-
Zack Tanner authored
There are a lot of things in here that aren't quite fully fleshed out yet (eg runtime prefetching) as well as some inaccuracies (eg `use cache: private` is not required for runtime prefetching, it's just another thing that _can_ be runtime prefetched). This trims the doc down until we can focus on proper guidance.
-
Steven authored
Swapping `is-local-address` for `ipaddr.js`
-
- 27 Oct, 2025 21 commits
-
-
nextjs-bot authored
-
Sebastian "Sebbie" Silbermann authored
-
Will Binns-Smith authored
- **Remove now-unnecessary feature flag for new_zeroed_alloc** - **Remove unused import** - **Update toolchain to 2025-10-27**
-
nextjs-bot authored
-
nextjs-bot authored
-
Sebastian "Sebbie" Silbermann authored
-
Zack Tanner authored
`prefetch={true}` with `cacheComponents` was opting into runtime prefetching, with `unstable_forceStale` preserving the old behavior of fetching the full (stale) data. However we only intended to expose runtime prefetching via the `export const prefetch` segment config. This removes `unstable_forceStale` and restores previous `prefetch={true}` behavior. I've disabled some of the tests that were relying on the old link behavior for opting into runtime prefetching - we'll need to refactor those to use the segment opt-in or just remove them all together. Fixes #85162 Closes NAR-320 -
Josh Story authored
These scopes aren't fully Next.js environments and can't access many Next.js APIs. In the future this might change but for now we will exclude the `next-js` condition when bundling for these entrypoints so that 3rd parties that target Next.js can do so with the expectation that regardless of what environment they are running in the full suite of Next.js libraries they support will work.
-
Sebastian "Sebbie" Silbermann authored
-
Mike Dyer authored
<!-- Thanks for opening a PR! Your contribution is much appreciated. To make sure your PR is handled as smoothly as possible we request that you follow the checklist sections below. Choose the right checklist for the change(s) that you're making: ## For Contributors ### Improving Documentation - Run `pnpm prettier-fix` to fix formatting issues before opening the PR. - Read the Docs Contribution Guide to ensure your contribution follows the docs guidelines: https://nextjs.org/docs/community/contribution-guide ### Fixing a bug - Related issues linked using `fixes #number` - Tests added. See: https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs - Errors have a helpful link attached, see https://github.com/vercel/next.js/blob/canary/contributing.md ### Adding a feature - Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. (A discussion must be opened, see https://github.com/vercel/next.js/discussions/new?category=ideas) - Related issues/discussions are linked using `fixes #number` - e2e tests added (https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs) - Documentation added - Telemetry added. In case of a feature if it's used or not. - Errors have a helpful link attached, see https://github.com/vercel/next.js/blob/canary/contributing.md ## For Maintainers - Minimal description (aim for explaining to someone not on the team to understand the PR) - When linking to a Slack thread, you might want to share details of the conclusion - Link both the Linear (Fixes NEXT-xxx) and the GitHub issues - Add review comments if necessary to explain to the reviewer the logic behind a change ### What? ### Why? ### How? Closes NEXT- Fixes # --> Co-authored-by:
JJ Kasper <jj@jjsweb.site>
-
Cody Coljee-Gray authored
Small grammar fix for fast-refresh.mdx <!-- Thanks for opening a PR! Your contribution is much appreciated. To make sure your PR is handled as smoothly as possible we request that you follow the checklist sections below. Choose the right checklist for the change(s) that you're making: ## For Contributors ### Improving Documentation - Run `pnpm prettier-fix` to fix formatting issues before opening the PR. - Read the Docs Contribution Guide to ensure your contribution follows the docs guidelines: https://nextjs.org/docs/community/contribution-guide ### Fixing a bug - Related issues linked using `fixes #number` - Tests added. See: https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs - Errors have a helpful link attached, see https://github.com/vercel/next.js/blob/canary/contributing.md ### Adding a feature - Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. (A discussion must be opened, see https://github.com/vercel/next.js/discussions/new?category=ideas) - Related issues/discussions are linked using `fixes #number` - e2e tests added (https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs) - Documentation added - Telemetry added. In case of a feature if it's used or not. - Errors have a helpful link attached, see https://github.com/vercel/next.js/blob/canary/contributing.md ## For Maintainers - Minimal description (aim for explaining to someone not on the team to understand the PR) - When linking to a Slack thread, you might want to share details of the conclusion - Link both the Linear (Fixes NEXT-xxx) and the GitHub issues - Add review comments if necessary to explain to the reviewer the logic behind a change ### What? Small grammer update on page introduction. ### Why? This makes the sentence more readable. ### How? N/A Closes NEXT- Fixes # --> Co-authored-by:
JJ Kasper <jj@jjsweb.site>
-
jesuistuan authored
The second “used” seems unnecessary. <!-- Thanks for opening a PR! Your contribution is much appreciated. To make sure your PR is handled as smoothly as possible we request that you follow the checklist sections below. Choose the right checklist for the change(s) that you're making: ## For Contributors ### Improving Documentation - Run `pnpm prettier-fix` to fix formatting issues before opening the PR. - Read the Docs Contribution Guide to ensure your contribution follows the docs guidelines: https://nextjs.org/docs/community/contribution-guide ### Fixing a bug - Related issues linked using `fixes #number` - Tests added. See: https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs - Errors have a helpful link attached, see https://github.com/vercel/next.js/blob/canary/contributing.md ### Adding a feature - Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. (A discussion must be opened, see https://github.com/vercel/next.js/discussions/new?category=ideas) - Related issues/discussions are linked using `fixes #number` - e2e tests added (https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs) - Documentation added - Telemetry added. In case of a feature if it's used or not. - Errors have a helpful link attached, see https://github.com/vercel/next.js/blob/canary/contributing.md ## For Maintainers - Minimal description (aim for explaining to someone not on the team to understand the PR) - When linking to a Slack thread, you might want to share details of the conclusion - Link both the Linear (Fixes NEXT-xxx) and the GitHub issues - Add review comments if necessary to explain to the reviewer the logic behind a change ### What? ### Why? ### How? Closes NEXT- Fixes # --> Co-authored-by:
Joseph <joseph.chamochumbi@vercel.com>
-
Sebastian "Sebbie" Silbermann authored
-
Sebastian "Sebbie" Silbermann authored
-
Joseph authored
Answers, how come I can return JSX from cache components?
-
Joseph authored
Also closes: https://github.com/vercel/next.js/issues/85344
-
Michael Hart authored
### Problem Both `polyfillTags` and `traceMetaTags` are only rendered if they haven't already been flushed, however the current check to skip rendering (lines 81-89) doesn't take this into account – only the render logic does (lines 93-98). This results in `renderToReadableStream` being called (potentially thousands of times – [for each chunk](https://github.com/vercel/next.js/blob/498349c375e2602f526f64e8366992066cfa872c/packages/next/src/server/stream-utils/node-web-streams-helper.ts#L368) in the [head insertion transform stream in the transformer chain](https://github.com/vercel/next.js/blob/498349c375e2602f526f64e8366992066cfa872c/packages/next/src/server/stream-utils/node-web-streams-helper.ts#L834)), constructing new `ReadableStream`s each time, just to render empty strings. It's present in canary/v16 and I suspect it was introduced in v15 (so can be backported). The logic check for v14 looks correct. ### Solution This PR ensures the shortcut check lines up with the render logic by just zeroing tag arrays after they've been used. There are a number of ways to achieve the same result – including just adding the `hasFlushedInitially` check to the shortcut logic – however this would result in the logic still being split in two places, so I've chosen one way to ensure the logic is centralized. Happy with whatever method is preferred here. ### Results This results in a 10-38% perf improvement end-to-end, especially for large renders. Eg, in [theo's benchmark](https://github.com/t3dotgg/cf-vs-vercel-bench/tree/main/next-bench) it brings the number of `renderToReadableStream` calls from 1745 here down to just 1, which has a noticeable impact on end-to-end performance I've [created a repo to highlight/reproduce the problem](https://github.com/mhart/next-server-inserted-fix) based off that benchmark. The results from there: - Node.js: 1.18x faster - Deno: 1.38x faster - workerd: 1.24x faster - Bun: 1.15x faster --------- Co-authored-by:
Josh Story <story@hey.com>
-
Jude Gao authored
-
denesbeck authored
Closes https://github.com/vercel/next.js/issues/84307 It seems that the `regexp` prop is not currently supported in the matcher object (./packages/next/src/build/segment-config/middleware/middleware-config.ts → MiddlewareMatcherInputSchema). Adjusting docs accordingly. --------- Co-authored-by:
devjiwonchoi <devjiwonchoi@gmail.com>
-
nextjs-bot authored
-
Remco Haszing authored
### What? This fixes a couple of things: - Although it’s rare for MDX plugins to accept more than 1 option, they may accept any number of arguments. - In addition to `remarkPlugins` and `rehypePlugins`, now `recmaPlugins` is also patched to accept strings - TypeScript property Descriptions are preserved for patched values. ### Why? Because it is broken. ### How? Fixes #77297
-
- 24 Oct, 2025 3 commits
-
-
nextjs-bot authored
-
Wyatt Johnson authored
### What? Adds depth-aware parameter resolution to `resolveParallelRouteParams` by migrating from simplified parallel route segments to LoaderTree structure. ### Why? Dynamic and intercepted parameters in parallel routes were not being correctly extracted when used at nested depths. The previous implementation didn't account for: - Route nesting level when matching pathname segments to parameters - Route groups (which don't affect depth) vs interception routes (which do) - Embedded parameters that need resolution before depth calculation This caused incorrect behavior in real-world scenarios like: - Nested parallel routes at different depths - Interception routes with parallel routes - ISR/generateStaticParams with complex routing structures ### How? 1. **LoaderTree Integration**: Migrated from `ParallelRouteSegment[]` to LoaderTree structure for accurate routing hierarchy representation 2. **Depth Tracking**: Recursively traverse LoaderTree to calculate depth, accounting for: - Static segments (increment depth) - Dynamic segments (increment depth) - Route groups `()` - don't increment depth - Interception routes `(.)` `(..)` `(...)` - do increment depth 3. **Smart Parameter Extraction**: - Check if pathname segment at calculated depth is a placeholder - Only extract if segment is known (not `[paramName]`) - Resolve embedded params before extraction 4. **Comprehensive Tests**: Added test coverage for: - Dynamic params at various depths - Route groups vs interception routes - Catchall/optional-catchall with depth - Complex nested scenarios Fixes #85251
-
Joseph authored
-