- 16 Mar, 2024 9 commits
-
-
vercel-release-bot authored
-
Tobias Koppers authored
### What? fixed `"use client"` in files ending with `d`... ### Why? ### How? Closes PACK-2753
-
vercel-release-bot authored
-
Tobias Koppers authored
### What? * Allow to apply webpack loaders depending on "conditions". * add a few next specific conditions depending on context type ### Why? Some loaders need different behavior depending on context ### How? Closes PACK-2748
-
Vercel Release Bot authored
This auto-generated PR updates the integration test manifest used when testing Turbopack.
-
Jiachi Liu authored
### What * The tags extracted from hydration errors could be "<div>" and "p", we need to stripe the brackets "<>" for matching the tag name from component stack * Change the dimmed text color to lighter so you can see it better in light mode #### After vs Before <img width="450" src="https://github.com/vercel/next.js/assets/4800338/6caed5ac-c073-41cc-a699-eb29f3785d59"> <img width="450" src="https://github.com/vercel/next.js/assets/4800338/926aa80f-2a49-4362-b77e-16b819955b0a"> Closes NEXT-2828
-
Jumpei Ogawa authored
Fixes #34448 Before this PR, next/lib/find-config fails to load \*.config.mjs files and \*.config.js files when `"type": "module"` is set in package.json. It expects CommonJS files although the \*.config.{js|mjs} files are written in JS modules format (i.e. using `import` and `export`). This PR fixes it so that it can load configs written in JS modules format. --------- Co-authored-by:Jiachi Liu <inbox@huozhi.im>
-
Josh Story authored
Error had a typo in it. it should be `force-dynamic` not `dynamic-error`. Closes NEXT-2827
-
Tobias Koppers authored
### What? We initially skipped a few test cases. We need to reenable them. ### Why? ### How? Closes PACK-2752
-
- 15 Mar, 2024 7 commits
-
-
Will Binns-Smith authored
Turbopack HMR: Log when more errors cause full page reload Depends on vercel/turbo#7715 This adds messaging when HMR updates fail because: - An HMR update could not be applied, such as updating an anonymous function component - An update follows a server-rendered error Test Plan: See now passing tests in the manifest Closes PACK-2728
-
vercel-release-bot authored
-
OJ Kwon authored
### What Small update to test fixture to make test stable. Closes PACK-2749
-
Jiachi Liu authored
### What In component diff view, dim the indirect components so that users can focus on the adjacent ones, and can easily locate the bad tags in visual. We still have the `^^^` text for jest snapshots, but they'll not visually displayed for users, as the red text is enough for users to notice the incorrect one and `^^^` was more like a terminal text styles that we don't need to bring them in the web UI. #### After <img width="400" src="https://github.com/vercel/next.js/assets/4800338/9a24f830-14b4-49a2-948a-5afbced8ec6f"> #### Before <img width="400" src="https://github.com/vercel/next.js/assets/4800338/c3ee593a-956b-447e-bad2-88007159d00f"> Closes NEXT-2826 Closes NEXT-2771
-
Tim Neutkens authored
## What? Makes sure changes to `optimizePackageImports` apply when there is an existing cache. <!-- 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 # --> Closes NEXT-2817
-
Vercel Release Bot authored
This auto-generated PR updates the integration test manifest used when testing Turbopack.
-
Donny/강동윤 authored
### What? Apply same patch as https://github.com/vercel/next.js/pull/62983 for `pages/_app.js` ### Why? To make turbopack match behavior of webpack mode, and make the test passs ### How? Closes PACK-2407
-
- 14 Mar, 2024 12 commits
-
-
Zack Tanner authored
This changes how loading components are provided to `LayoutRouter` to instead be part of the `CacheNode`. This makes it so that we can copy it over/expire it in a similar way to the `data` property on a `CacheNode`. Consequently, this fixes a bug in PPR navigations, where 2 different loading states (the prefetched one, followed by the updated one) might be displayed upon navigating. Note: This disables a PPR test that asserts the loading data gets expired after 5 minutes. As implemented, the loading data will remain cached for a particular segment. <!-- 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 # --> Closes NEXT-2557
-
vercel-release-bot authored
-
Ziya Fenn 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 ### 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 # --> Current URL points to a non-existing anchor. Updated url to point to next-config options.
-
Steven authored
Closes https://github.com/vercel/next.js/pull/63276 Closes NEXT-2818
-
Jiachi Liu authored
There's a type of hydration warning is mismatch `"text content"` under a `<tag>`, such as `Did not expect server HTML to contain the text node "bad text" in <div>.`, we need to treate them separately from the text diff or bad neseting tags. ### After  ### Before  Closes NEXT-2819
-
vercel-release-bot authored
-
Vercel Release Bot authored
This auto-generated PR updates the integration test manifest used when testing Turbopack.
-
Donny/강동윤 authored
# Turbopack changes * https://github.com/vercel/turbo/pull/7726 <!-- OJ Kwon - feat(node): augment webpack loader's logger context --> * https://github.com/vercel/turbo/pull/7729 <!-- Donny/강동윤 - Update `swc_core` to `v0.90.22` -->
-
Tobias Koppers authored
### What? * rename test case * improve error message and handle edge case for require resolving * fix test case actually testing externals (webpack was silently bundling, Turbopack showed error that helped to find the broken test case) ### Why? ### How? Closes PACK-2662
-
Dima Voytenko authored
Fixes #63127.
-
Donny/강동윤 authored
### What? Subscribe to changes of `_error` pages. ### Why? To make the error overlay disappear when the error is fixed. I tried skipping related entries by using `continue;` from https://github.com/vercel/next.js/blob/5f3b13584ce87eac00f8b801c24a5de14a0a3ed9/packages/next/src/server/dev/hot-reloader-turbopack.ts#L675-L684, but it resulted in it page being rendered in the background while error overlay does not disappear. We need to remove the errors from `/_error` page to make the error overlay disappear, so I tried removing them from the map and it worked. ### How? Closes PACK-2405 Closes PACK-2644 --------- Co-authored-by:
hrmny <8845940+ForsakenHarmony@users.noreply.github.com>
-
Sam Ko authored
## Why? When we just have a POST route handler, it seems CORs is not working properly. This is because we break out of the loop here https://github.com/vercel/next.js/blob/768a92b15bd72002df0f9f893d78e094a8e3165f/packages/next/src/server/future/route-modules/app-route/helpers/auto-implement-methods.ts#L38 when a `GET` isn't present before we add the correct headers and status to the preflight `OPTION`. - Closes https://github.com/vercel/next.js/issues/57999 Closes NEXT-2813 --------- Co-authored-by:
JJ Kasper <jj@jjsweb.site>
-
- 13 Mar, 2024 12 commits
-
-
vercel-release-bot authored
-
JJ Kasper authored
This ensures we properly set the matched header when applying a middleware skip optimization so that the client router has enough context to finish resolving the dynamic route params. Fixes: https://github.com/vercel/next.js/issues/59561 Closes NEXT-2803
-
Steven authored
This PR stabilizes an experimental feature that was added in a previous PR https://github.com/vercel/next.js/pull/50470 It allows the user to set `deploymentId` in `next.config.js`, which is a unique identifier for a deployment that will be included in each request's query string or header. This PR is easier to review with whitespace hidden: https://github.com/vercel/next.js/pull/63198/files?w=1 Closes NEXT-2789
-
OJ Kwon authored
### What This is stopgap substitution to webpack's wellknownerrorsplugin. When webpack compilation hits known errors kind it emits compilation errors into cli (and dev overlay both) while turbopack currently only emits into error overlay. PR simply detects if given issue is well known, and then logs into std. Probably a long term there should be proper wiring instead; but for now this allows to make few things work out of the box. Closes PACK-2727
-
Ethan Arrowood authored
Enable the `experimental#optimizeServerReact` configuration by default. Disable the `optimize_use_state` option for the optimization as this may cause issues in React 19 Closes NEXT-2640
-
michaltarasiuk authored
Update 02-server-actions-and-mutations.mdx - add required generic type and remove unnecessary parameter types (#62551) - Resolve generic type issue: "Expected 1 argument, received 2." - Types in the reducer are automatically inferred. Co-authored-by:Sam Ko <sam@vercel.com>
-
JJ Kasper authored
This adds automatic tarball deployments for each build so that we don't have to trigger a canary release whenever we want to create a full tarball with all `next-swc` builds. Example tarball https://github.com/vercel/next.js/actions/runs/8239762627/job/22534810077#step:9:34 Closes NEXT-2735
-
michaltarasiuk authored
FormData objects are iterable, so we can get entries directly without the need for calling .entries(). Co-authored-by:Sam Ko <sam@vercel.com>
-
Ellert Smári Kristbergsson authored
Update MongoDB according to their guidance for their new Stable API See: https://www.mongodb.com/docs/drivers/node/current/fundamentals/stable-api/ <!-- 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:
Sam Ko <sam@vercel.com>
-
Cody Olsen authored
As `@sanity/preview-url-secret` wasn't declared as a dependency when doing: ```bash pnpm install && pnpm build ``` It would fail to compile: ```bash Linting and checking validity of types .Failed to compile. ./app/api/draft/route.tsx:6:36 Type error: Cannot find module '@sanity/preview-url-secret' or its corresponding type declarations. 4 | */ 5 | > 6 | import { validatePreviewUrl } from "@sanity/preview-url-secret"; | ^ 7 | import { draftMode } from "next/headers"; 8 | import { redirect } from "next/navigation"; 9 | ``` -
Donny/강동윤 authored
### What? Make turbopack not emit HMR timing report twice. ### Why? We should not report HMR update twice. ### How? Closes PACK-2581 --------- Co-authored-by:Tobias Koppers <tobias.koppers@googlemail.com>
-
vercel-release-bot authored
-