- 16 Nov, 2022 16 commits
-
-
JJ Kasper authored
-
JJ Kasper authored
Fixes: https://github.com/vercel/next.js/issues/43001 ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
JJ Kasper authored
This test has been flakey due to the timeout occasionally being hit. x-ref: https://github.com/vercel/next.js/actions/runs/3483651647/jobs/5827421628
-
Chancellor Clark 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 that you're making: --> ## Bug Bumps `eslint-import-resolver-typescript` in `eslint-config-next` to the latest version to pick up a fix from `3.1.0`. As mentioned here, https://github.com/import-js/eslint-import-resolver-typescript/issues/107, the typescript parser is unable to resolve the `typesVersions ` field in their `package.json`. An example repo using this is [`@vercel/examples-ui`](https://github.com/vercel/examples/blob/385a2e968619f9e50f488e2857e021841ae61030/packages/ui/package.json#L14-L22) which will report an eslint `import/no-unresolved` error when using the previous version of `eslint-import-resolver-typescript` (see https://github.com/import-js/eslint-import-resolver-typescript/issues/107). This was fixed in https://github.com/import-js/eslint-import-resolver-typescript/pull/110 This can be locally fixed by bumping `>=eslint-import-resolver-typescript@3.1.0` but decided it should be resolved here too. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [x] Errors have a helpful link attached, see `contributing.md` Closes: https://github.com/vercel/next.js/pull/41786Co-authored-by:
JJ Kasper <jj@jjsweb.site>
-
Vu Van Dung 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 that you're making: --> ## Summary In `appDir`, currerntly `generateStaticParams` must be an `async` function, even if no data fetching or asynchronous operations are involved. For example, with this ```ts // app/[slug]/page.tsx export async function generateStaticParams() { return [{ slug: "Hello" }]; } ``` if I remove the `async` keyword, `next build` type checking will fail with a rather unclear error message ``` Type error: Page "app/[slug]/page.tsx" does not match the required types of a Next.js Page. ``` However `next dev` still works fine, and after applying the type change in this PR, `next build` and `next start` will also work fine. Considering that `getStaticPaths` can be synchronous, this requirement of `async` is pretty confusing. Many people have reported this type error for not marking `generateStaticParams` as `async` (me included). This PR lifts the restriction and allows `generateStaticParams` to be synchronous. (If it's intentional that `generateStaticParams` must be asynchronous, feel free to close this PR, but I don't think that restriction is a good idea...) Since I cannot find any test cases on the type checking process, I'm a bit unsure in how to write a test case for this... or if a test case is even necessary at all. ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md) -
Hannes Bornö authored
When building (`next/build/index.ts`) files ending with `page.js` got picked up by the RegEx which meant files like `not-a-page.js` ended up as a page. This change makes sure the segment actually starts with `page`. Dev had the same issue and also missed taking `pageExtensions` into account. Fixes #42972 ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
JJ Kasper authored
This ensures we document the regions config for `experimental-edge`. x-ref: [slack thread](https://vercel.slack.com/archives/C0289CGVAR2/p1668624228564539) x-ref: https://github.com/vercel/next.js/pull/40881 ## Documentation / Examples - [x] Make sure the linting passes by running `pnpm build && pnpm lint` - [x] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
Max Proske authored
SWC minification is now [enabled by default](https://nextjs.org/docs/advanced-features/compiler) in the Next.js compiler. ## Documentation / Examples - [X] Make sure the linting passes by running `pnpm build && pnpm lint` - [X] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
JJ Kasper authored
As noticed in https://github.com/vercel/next.js/pull/42966#pullrequestreview-1181705091 we weren't resetting tests correctly on retry causing an incorrect pass. ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
Balázs Orbán authored
fixes #42964 ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md) Co-authored-by:
JJ Kasper <jj@jjsweb.site> Co-authored-by:
Bryce Kalow <br.kalow@gmail.com>
-
Tim Neutkens authored
-
Max Proske authored
-
Max Proske authored
-
Max Proske authored
-
Silvio Clécio authored
-
OJ Kwon 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 that you're making: --> **I'm not sure if this is legit to fix, shared context below** This PR attempts to fix test fixtures to reflect test failures. On my working branch has unrelated changes to `next-env.d.ts` declaration. I started to seeing intermittent test failures on CI, as well as local. It was nearly 100% reproducible on local, while on CI it was nearly not reproducible but only appears intermittently. Some code archaeology leads me to this PR https://github.com/vercel/next.js/pull/28316, specifically https://github.com/vercel/next.js/commit/77150dac791d63be87af9cbfae1b0c5b17da5267#diff-9495c8b2cd0a5f2c471a37c24eac56caba4bd5cf95e2d021f95c4718e3191b47L33 seems implying test fixture need to be updated. However, I can't figure out why this does not fail in CI since changes landed. Please feel free to close out if this is not expected changes. It is entirely possible my setup have some weird side effect to cause test failures. ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md) Co-authored-by:
JJ Kasper <jj@jjsweb.site>
-
- 15 Nov, 2022 13 commits
-
-
JJ Kasper authored
This deployment is no longer available so this replaces it with a fresh one. Fixes: https://github.com/vercel/next.js/actions/runs/3473226521/jobs/5807106060 Fixes: https://github.com/vercel/next.js/actions/runs/3473226521/jobs/5807102445
-
Zeki Can Ekşi authored
just a small typo
-
JJ Kasper authored
-
-
JJ Kasper authored
Ensures we have the actual target passed into turbo for all builds so it's considered for the cache key. Fixes: https://github.com/vercel/next.js/actions/runs/3472341903/jobs/5803170296
-
Jamie Barton authored
-
JJ Kasper authored
-
JJ Kasper authored
Updates to leverage turbo remote caching for the swc builds and normalize the package versions to prevent repo version bumps from un-necessarily invalidating the cache. Full cache hits can be seen in this test run https://github.com/vercel/next.js/actions/runs/3469932131/jobs/5797559609
-
Hannes Bornö authored
Fixes: #42587 ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
Adil Ansari authored
-
Max Proske authored
Converted example to TypeScript to match Contribution docs. ## Documentation / Examples - [X] Make sure the linting passes by running `pnpm build && pnpm lint` - [X] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
OJ Kwon 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 that you're making: --> This PR exposes internal injection point to specify custom binary / bindings for the turbopack. It doesn't affect any existing native bindings (swc), but only allows to run custom turbopack (`turbo.startDev`) if specified. The changes are mostly for the internal dev / testing iteration purpose. Currently, the workflow to test new turbopack changes in next.js is - update next-swc's cargo to point to specific changes in turbopack - rebuild, specify next.js to use local binary This requires additional build times (turbopack build cannot be used, have to rebuild next-swc napi bindings) as well as if we'd like to try some changes on the CI between next.js canary + latest turbopack, integration gets bit tricky. 2 env variable is exposed for the purpose - `__INTERNAL_CUSTOM_TURBOPACK_BINARY` stands for the executable binary (next-dev) can be built in turbopack, `__INTERNAL_CUSTOM_TURBOPACK_BINDINGS` stands for the custom napi bindings if needed. Both are strictly internal as name implies. There won't be any documentation, no semver guarantee or else. Current plan is to execute some subset of next.js test on turbopack PRs with these entrypoints. Feature / security wise these are mostly harmless I believe - this is devserver usually don't run on CI, and trying to print out warning if flag is enabled. ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md) Co-authored-by:
JJ Kasper <jj@jjsweb.site>
-
JJ Kasper authored
x-ref: [slack thread](https://vercel.slack.com/archives/C035J346QQL/p1668195556550659) Fixes: https://github.com/vercel/next.js/issues/42463 ## Bug - [x] Related issues linked using `fixes #number` - [x] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
- 14 Nov, 2022 11 commits
-
-
JJ Kasper authored
This adds some more clarity to the error doc and we can also iterate on the warnings to show suggestions as well in follow-ups. x-ref: [slack thread](https://vercel.slack.com/archives/CHZGRCJSD/p1668430036939189?thread_ts=1668394104.483679&cid=CHZGRCJSD) ## Documentation / Examples - [x] Make sure the linting passes by running `pnpm build && pnpm lint` - [x] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
Steven Tey 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 that you're making: --> ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
Sukka 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 that you're making: --> The PR closes #42003. Replace `(e: any) => void` with `React.MouseEventHandler<HTMLAnchorElement>` and `React.TouchEventHandler<HTMLAnchorElement>`. The original typing overlap issue has also been fixed. ## Bug - [x] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md`
-
Tim Neutkens authored
Fixes https://github.com/vercel/next.js/pull/42735#discussion_r1019116319. <!-- 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 that you're making: --> ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
JJ Kasper authored
Continuation of https://github.com/vercel/next.js/pull/42711 fixing latest turbo usage in musl environment ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
Steven Tey authored
## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `pnpm build && pnpm lint` - [ ] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-
Lee Robinson authored
This is now ready for review. Co-authored-by:Hassan El Mghari <hassan4709@gmail.com>
-
Damien Simonin Feugas authored
##
📖 What's in there? The last example on the documentation page for [Edge Api routes](https://nextjs.org/docs/api-routes/edge-api-routes) is wrong since next@13 breaking change on cookie handling. While [middleware page](https://nextjs.org/docs/advanced-features/middleware#using-cookies) is updated, this one was left off. -
Tim Neutkens authored
-
Kolton Gagnon authored
Updated `.vscode/launch.json` debugging file due to the following errors: - `console: pwa-chrome` shows an eslint error recommending `console: chrome` - `console` key is now deprecated. Tested client and server-side debugging on: - Mac v12.6 (21G115) - VSCode v1.73.1 - Chrome v107.0.5304.110 See attached screenshots for linting errors. **console: pwa-chrome** <img width="464" alt="CleanShot 2022-11-12 at 22 06 15@2x" src="https://user-images.githubusercontent.com/3606121/201502364-e796b1a0-51a5-4aee-8bcf-8828e03f244a.png"> **`console`** <img width="503" alt="CleanShot 2022-11-12 at 22 06 37@2x" src="https://user-images.githubusercontent.com/3606121/201502369-55d75a93-360f-4d67-ba15-438d683c041b.png"> ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have a helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have a helpful link attached, see `contributing.md` ## Documentation / Examples - [X] Make sure the linting passes by running `pnpm build && pnpm lint` - [X] The "examples guidelines" are followed from [our contributing doc](https://github.com/vercel/next.js/blob/canary/contributing/examples/adding-examples.md)
-