- 23 Oct, 2024 20 commits
-
-
vercel-release-bot authored
-
Zack Tanner authored
Since `console.error` is intercepted, this can be frustrating when a 3p library that hasn't updated to use the async APIs triggers a warning. This keeps the error behavior when `dynamicIO` is enabled and warns in other cases.
-
Jiwon Choi authored
next-codemod: add empty `pnpm-workspace.yaml` to test fixtures to bypass PNPM workspace checks (#71726) ### Why? Since dep installation within next-codemod runs `pnpm install` on the Next.js repo, it installs in the workspace root scope during testing. We could add a layer for testing like adding a flag `--no-workspace`, but it will reduce confidence between the actual running and testing. Therefore added an empty `pnpm-workspace.yaml` file to each fixture. ### How? By doing this, both installation and testing will have same environment of running, `pnpm install` only. To prevent created `pnpm-lockfile` to be shipped, gitignored it. This way, we keep things simple and make sure tests match real-world use better. The empty `pnpm-workspace.yaml` files make `pnpm` treat each fixture separately, which is closer to how it'll work for users.
-
Jiachi Liu authored
-
Sebastian "Sebbie" Silbermann authored
`npm view` prints a notice when a new update is available to `stderr` tricking us into thinking there was an error. ``` npm notice npm notice New minor version of npm available! 10.7.0 -> 10.9.0 npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.9.0 npm notice To update run: npm install -g npm@10.9.0 npm notice ``` Running with `--silent` avoids these unrelated warnings (see https://github.com/npm/npm/issues/2040#issuecomment-3504495). ## Test plan https://github.com/vercel/next.js/pull/71718
-
Jiachi Liu authored
-
Miguel da Mota authored
This PR fixes #71706. When having an error client side and there is a `basePath` defined, the basePath is being used to locate the sourcemap of the given file which results in an error. With these changes the `basePath` gets removed from the `filename` passed to `findSourceMapURL` If you have questions, feel free to ask!
-
Hendrik Liebau authored
-
Prakhar Shukla authored
### Why? During the next-codemod upgrade, when the `dev` script is missing, it throws while reading `.includes` the undefined value. Fixes #71597 --------- Co-authored-by:Jiwon Choi <devjiwonchoi@gmail.com>
-
Jiwon Choi authored
### Why? When handling the opengraph-image size exceeding the limit, we mapped with string literal between Rust and JavaScript. The Rust string literal contains backslashes `\` on Windows, incompatible with JavaScript string syntax. Following up on #71615. Fixes #71582
-
Sam Ko authored
## Why? [`appIsrStatus`](https://nextjs.org/docs/canary/app/api-reference/next-config-js/devIndicators#appisrstatus-static-indicator) is stable now, so this note is no longer necessary.
-
Josh Story authored
In the initial change to adopt prerender for SSR for dynamicIO I missed an instance of renderToReadableStream. This completes the work
-
マルコメ authored
## Description At #44405, many files moved. Then sync comment paths. Co-authored-by:JJ Kasper <jj@jjsweb.site>
-
tatsuteb authored
The json() method returns a Response object, so remove the new keyword. <!-- 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 ### Adding or Updating Examples - The "examples guidelines" are followed from our contributing doc https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md - Make sure the linting passes by running `pnpm build && pnpm lint`. See https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md ### 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>
-
Sebastian Ong authored
### What? Fixes the `params` prop in https://nextjs.org/docs/canary/app/building-your-application/routing/dynamic-routes Also fixes a typo: `synchronoulsy` -> `synchronously` ### Why? There is a breaking change in `next@15.0.0-rc.1`: https://nextjs.org/blog/next-15-rc2#async-request-apis-breaking-change Although the api docs have been updated, these have not been. ### How? updates the docs. (relevant) build and lint passes locally. ran the prettier fix. --------- Co-authored-by:
JJ Kasper <jj@jjsweb.site>
-
Jiachi Liu authored
-
Jiachi Liu authored
-
Hendrik Liebau authored
This avoids a race condition when running `next build` where the manifest singleton might be overwritten with the next page's manifest while the previous page is still being rendered. With this PR, we are not storing a page-specific singleton but the whole manifest, and only when accessing an entry is the page read from the work store, and thus scoped to the current page. An exception is when a server module map is needed during module evaluation when no work store is provided, e.g. to create a server action using a higher-order function. In this case it should be safe to return any entry from the manifest that matches the action ID. They all refer to the same module ID, which must also exist in the current page bundle. (This is currently not guaranteed in Turbopack, and needs to be fixed.)
-
ytori authored
This PR fixes a broken link (404 Not Found) in the [Architecture/Turbopack](https://nextjs.org/docs/architecture/turbopack) documentation. It appears the actual URL differs from the expected one, so I have corrected it to the expected URL. expected URL : https://nextjs.org/docs/canary/architecture/nextjs-compiler#supported-features actual URL : https://nextjs.org/docs/canary/architecture/docs/canary/architecture/nextjs-compiler#supported-features  Co-authored-by:
JJ Kasper <jj@jjsweb.site>
-
vercel-release-bot authored
-
- 22 Oct, 2024 20 commits
-
-
vercel-release-bot authored
-
Josh Story authored
Component stacks in dev are sourcemapped and currently there is a bug that prevents the right function name from showing up which interrupts our ability to detect incomplete metadata in dev
-
Tim Neutkens authored
Changes `--turbo` -> `--turbopack` to avoid confusion. - Updated docs - Updates create-next-app -- For create-next-app it's a rename as otherwise there is an ordering problem with the prompts - For the CLI `next dev --turbo` is still supported, will eventually be a warning in a future version to swap with `--turbopack` but is not a requirement today, can be handled automatically by the upgrade codemod - New CLI flag: `next dev --turbopack` <!-- 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 ### Adding or Updating Examples - The "examples guidelines" are followed from our contributing doc https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md - Make sure the linting passes by running `pnpm build && pnpm lint`. See https://github.com/vercel/next.js/blob/canary/contributing/repository/linting.md ### 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:
Will Binns-Smith <wbinnssmith@gmail.com>
-
Benjamin Woodruff authored
**This is a** *(mostly)* **machine-generated PR.** This uses a much updated version of the ast-grep based codemod script from #70927, which can now match a bunch more patterns. Codemod scripts: https://github.com/vercel/turbopack-resolved-vc-codemod/tree/90518e64cfaf9328546ff4688692f16f54d4fc3e I did a small bit of cleanup after running the script with: ```bash sg -U --pattern '$OBJ.resolve().await?.to_resolved().await?' -r '$OBJ.to_resolved().await?' ``` Notable additions since last time are: - Runs the compiler/fixer in a loop a few times, as fixing an issue often allows compilation to get further, creating new errors. - Can apply compiler-suggested edits (usually these are manual derefs needed with `*`) - Knows how to rewrite `$OBJ.cell()` to `$OBJ.resolved_cell()` - Knows how to rewrite `Vc::cell($ARG)` to `ResolvedVc::cell($ARG)` - Knows how to rewrite `$TYPE::cell($ARG)` to `$TYPE::resolved_cell($ARG)`. - Knows how to add `.to_resolved().await?` to expressions.
-
Cody Olsen authored
-
Sebastian "Sebbie" Silbermann authored
Now `pnpm debug` is like `pnpm next` with `NODE_OPTIONS=--inspect`
-
Jiachi Liu authored
-
Benjamin Woodruff authored
Caught this missing implementation when the codemod in #71172 tried to convert this test to use `ResolvedVc`. This implementation just forwards to the one on `Vc`. I don't think we need an explicit test case for `Vc` inside of a struct, because the plan is to codemod away virtually every instance of this. Co-authored-by:Niklas Mischkulnig <4586894+mischnic@users.noreply.github.com>
-
Jiachi Liu authored
The note of `onRequestError` API is outdated, it's available on v15 stable now Fixes #71634
-
Steven authored
There was an extra backtick causing a format error. https://nextjs.org/docs/app/api-reference/components/image#src <img width="664" alt="image" src="https://github.com/user-attachments/assets/2792e71b-f3a7-4790-80a0-eecb5210753a">
-
Ivan Vasilov authored
Co-authored-by:Lee Robinson <me@leerob.io>
-
Sebastian "Sebbie" Silbermann authored
-
Sebastian "Sebbie" Silbermann authored
-
Jiachi Liu authored
-
vercel-release-bot authored
-
Niklas Mischkulnig authored
A regression from https://github.com/vercel/turborepo/pull/8748 Closes PACK-3312 Previously, it treated imports to `something.mjs` as importing `something.mts` with a fallback to `something.js`. But it should obviously instead fallback to the original extension `mjs`, which is also what tsc does: ``` Found 'package.json' at 'input/package.json'. ======== Resolving module './src/foo.mjs' from 'input/index.js'. ======== Explicitly specified module resolution kind: 'NodeNext'. Resolving in CJS mode with conditions 'require', 'types', 'node'. Loading module as file / folder, candidate module location 'input/src/foo.mjs', target file types: TypeScript, JavaScript, Declaration. File name 'input/src/foo.mjs' has a '.mjs' extension - stripping it. File 'input/src/foo.mts' does not exist. File 'input/src/foo.d.mts' does not exist. File 'input/src/foo.mjs' does not exist. File 'input/src/foo.mjs.ts' does not exist. File 'input/src/foo.mjs.tsx' does not exist. File 'input/src/foo.mjs.d.ts' does not exist. File 'input/src/foo.mjs.js' does not exist. File 'input/src/foo.mjs.jsx' does not exist. Directory 'input/src/foo.mjs' does not exist, skipping all lookups in it. ======== Module name './src/foo.mjs' was not resolved. ======== ```
-
Jiachi Liu authored
-
Janka Uryga authored
Our patched `console.error` tries to skip internal router errors by checking `isNextRouterError(error)`. however, if one of those happened on the server and got replayed on the client, it gets logged differently -- it's prefixed with the `[ Server ]` badge. this changes the position where the actual error object is in `args` and thus messes up our detection, so we end up printing it out (instead of hiding it like we should) This PR adds a check that attempts to match replayed server errors (following [similar logic from react devtools](https://github.com/facebook/react/blob/65a56d0e99261481c721334a3ec4561d173594cd/packages/react-devtools-shared/src/backend/flight/renderer.js#L88-L93)) and thus also filter out router errors that originated on the server Closes #71555
-
Jiwon Choi authored
### Why? When handling the `opengraph-image` size exceeding the limit, we mapped with string literal between Rust and JavaScript. The Rust string literal contains backslashes `\` on Windows, incompatible with JavaScript string syntax. Fixes #71582 --------- Co-authored-by:Donny/강동윤 <kdy1997.dev@gmail.com>
-
Jiwon Choi authored
### Why? Since ESLint v9 was unblocked, we no longer need to pin installing v8 when running `next lint` for the first time.
-