- 12 May, 2022 8 commits
-
-
JJ Kasper authored
-
Jiachi Liu authored
Follow up for #35888 to re-enable more test, and re-enable post processors after #36792 has better support for document.gIP with react 18. Apply post-pocessing when the the shell chunk is fully buffered. re-enabled integration tests for react 18: - amphtml - amphtml-custom-optimizer - app-document - font-optimization Fixes #35835 ## Bug - [x] Related issues linked using `fixes #number` - [x] Integration tests added - [ ] Errors have helpful link attached, see `contributing.md`
-
Jiachi Liu authored
## Documentation / Examples - [x] Make sure the linting passes by running `yarn lint`
-
JJ Kasper authored
This adds an experimental config for testing `basePath` handling on the client. x-ref: [slack thread](https://vercel.slack.com/archives/CLDDX2Y0G/p1652221605742559) ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
-
Robert Keyser authored
copy/pasting the SCSS example into VSCode results in linter warning. Fixed with semicolon on variable assignment. Added the second semicolon for consistency. ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint` Co-authored-by:JJ Kasper <22380829+ijjk@users.noreply.github.com>
-
Balázs Orbán authored
Ref: https://github.com/vercel/next.js/issues/36842, https://github.com/vercel/next.js/pull/36632, https://github.com/vercel/next.js/pull/36787 Upgrading to Jest 28, and aligning Babel example with `with-jest` ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
-
Rich Haines authored
This PR updates the copy in the source maps section of the docs to reflect the improvement made to webpack that generate source maps. ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
-
JJ Kasper authored
Follow-up to https://github.com/vercel/next.js/pull/36612 this updates to eagerly load the swc bindings unless babel is being used so that we don't wait for the transform calls to initialize swc. Eagerly loading in jest also allows us to fallback to the wasm bindings when previously we couldn't since they needed to wait for the import.
-
- 11 May, 2022 7 commits
-
-
Houssein Djirdeh authored
Track usage of the experimental `nextScriptWorkers` flag. Backend PR: https://github.com/vercel/next-telemetry/pull/75 https://nextjs.org/docs/basic-features/script#off-loading-scripts-to-a-web-worker-experimental
-
Sukka authored
## Bug - [x] Related issues linked using `fixes #number` - [x] Integration tests added - [ ] Errors have helpful link attached, see `contributing.md` The PR fixes #30300. The previous integration test case only checks if `/out/404.html` exists. However, the test passes since `/out/404.html/index.html` is being exported instead. The PR changes that by checking if a given path exists and is a file.
-
Sukka authored
-
Hannes Bornö authored
Stack trace disappears when error is converted to string. I changed the types in `log.ts` to match `console.log`/`console.error`/`console.warn`. fixes #31591
-
LongYinan authored
Close https://github.com/vercel/next.js/issues/36639 Build successfully: https://github.com/vercel/next.js/actions/runs/2305589556
-
JJ Kasper authored
-
Jiachi Liu authored
When getInitialProps is customized with react 18, since gIP requires to return `html` as doc property which could be used by user-land customization, we do blocking-rendering there and passdown the `html` to document Fixes #36675 Closes #36419
-
- 10 May, 2022 7 commits
-
-
JJ Kasper authored
* Update moduleNameMapper jest config and remove extra deps * move svg mock to its own entry for easier overriding * remove package script
-
Shu Ding authored
* move FlightManifestPlugin to server compilers * revert loader condition * fix module id * fix test and refactor Co-authored-by:kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
-
James Perkins authored
## Documentation / Examples - Updating Tina Demo URL - Adding Tina to blog-starter example - Adding Tina to Basic features section - Updating Tina to actually work again
-
Remco Haszing authored
This aligns the output with what npm outputs. Without this change, Next.js causes unwanted changes in package-lock.json. ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [x] Make sure the linting passes by running `yarn lint`
-
JJ Kasper authored
-
Marzouq authored
## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [x] Make sure the linting passes by running `yarn lint`
-
Erik Brinkman authored
fixes #36763 fixes #36590 ## Feature - [x] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - It hasn't been accepted for implementation, although that process isn't clear, and this is a pretty trivial fix. - [x] Related issues linked using `fixes #number` - [x] Integration tests added - [x] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - This is somewhat inherent in the error log - [x] Errors have helpful link attached, see `contributing.md` ## Documentation / Examples - [x] Make sure the linting passes by running `yarn lint`
-
- 09 May, 2022 4 commits
-
-
JJ Kasper authored
-
Tim Neutkens authored
Co-authored-by:JJ Kasper <jj@jjsweb.site>
-
Balázs Orbán authored
We have tests running on the examples repository that will fail if `name` or `version` is found in the `package.json`. We should make it more clear in the documentation to omit these fields. @ijjk ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
-
Kiko Beats authored
This PR introduces a more predictable API to manipulate cookies in an Edge Function context. ```js const response = new NextResponse() // set a cookie response.cookies.set('foo, 'bar') // => set-cookie: 'foo=bar; Path=/'` // set another cookie response.cookies.set('fooz, 'barz') // => set-cookie: 'foo=bar; Path=/, fooz=barz; Path=/'` // delete a cookie means mark it as expired response.cookies.delete('foo') // => set-cookie: 'foo=; Path=/; Expires=Thu, 01 Jan 1970 00:00:00 GMT, fooz=barz; Path=/'` // clear all cookies means mark all of them as expired response.cookies.clear() // => set-cookie: 'fooz=; Path=/; Expires=Thu, 01 Jan 1970 00:00:00 GMT, foo=; Path=/; Expires=Thu, 01 Jan 1970 00:00:00 GMT'` ``` This new cookies API uses [Map](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map) interface, and it's available for `NextRequest` and `NextResponse`. Additionally, you can pass a specific cookies option as a third argument in `set` method: ```js response.cookies.set('foo', 'bar', { path: '/', maxAge: 60 * 60 * 24 * 7, httpOnly: true, sameSite: 'strict', domain: 'example.com' } ``` **Note**: `maxAge` it's in seconds rather than milliseconds. Any cookie manipulation will be reflected over the `set-cookie` header, transparently. closes #31719
-
- 08 May, 2022 2 commits
-
-
Tim Neutkens authored
## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
-
Sukka authored
- [x] Make sure the linting passes by running `yarn lint` Back in 2019, React released the first version of `use-subscription` (https://github.com/facebook/react/pull/15022). At the time, we only has limited information about concurrent rendering, and #9026 add the initial concurrent mode support. In 2020, React provides a first-party official API `useMutableSource` (https://github.com/reactjs/rfcs/pull/147, https://github.com/facebook/react/pull/18000): > ... enables React components to safely and efficiently read from a mutable external source in Concurrent Mode. React 18 introduces `useMutableSource`'s replacement `useSyncExternalStore` (see details here: https://github.com/reactwg/react-18/discussions/86), and React changes `use-subscription` implementation to use `useSyncExternalStore` directly: https://github.com/facebook/react/pull/24289 > In React 18, `React.useSyncExternalStore` is a built-in replacement for `useSubscription`. > > This PR makes `useSubscription` simply use `React.useSyncExternalStore` when available. For pre-18, it uses a `use-sync-external-store` shim which is very similar in `use-subscription` but fixes some flaws with concurrent rendering. And according to `use-subscription`: > You may now migrate to [`use-sync-external-store`](https://www.npmjs.com/package/use-sync-external-store) directly instead, which has the same API as `React.useSyncExternalStore`. The `use-subscription` package is now a thin wrapper over `use-sync-external-store` and will not be updated further. The PR does exactly that: - Removes the precompiled `use-subscription` introduced in #35746 - Adds the `use-sync-external-store` to the dependencies. - The `use-sync-external-store` package enables compatibility with React 16 and React 17. - Do not pre-compile `use-sync-external-store` since it is also the dependency of some popular React state management libraries like `react-redux`, `zustand`, `valtio`, `@xstate/react` and `@apollo/client`, etc. By install - Replace `useSubscription` usage with `useSyncExternalStore` --- Ref: #9026, #35746 and #36159 Co-authored-by:
Jiachi Liu <4800338+huozhi@users.noreply.github.com>
-
- 07 May, 2022 4 commits
-
-
Steven Tey authored
## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
-
Jiachi Liu authored
x-ref: https://github.com/vercel/next.js/pull/36552#issuecomment-1120128946 x-ref: https://github.com/preactjs/next-plugin-preact/pull/59 `preact/compat` doesn't have `/server.browser` exports, to make it work with latest of next.js: * use `react-dom/server` to detect if it could opt-in streaming rendering by checking react 18 `renderToPipeableStream` API in short time fix. In long term `preact/compat`should support `/server.browser` that same with react 17. * Also filed a PR to `next-plugin-preact` to skip chunk-prepending to pages in edge compiler
-
Tim Neutkens authored
## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
-
Rich Haines authored
…rding due to customer confusion This PR updates the middleware (edge functions) api docs environment section to remove the dev and prod wording due to customer confusion ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have 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 helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
-
- 06 May, 2022 2 commits
-
-
Tim Neutkens authored
-
Tim Neutkens authored
-
- 05 May, 2022 6 commits
-
-
Jiachi Liu authored
the rsc & streaming test app is too big to build which is time consuming, move custom _app cases to switchable runtime test suite
-
Tim Neutkens authored
* Add route loader * Update to leverage new view-loader * fix lint Co-authored-by:JJ Kasper <jj@jjsweb.site>
-
Jiachi Liu authored
Fixes #36659 `App` is alreay included in `ServerComponentWrapper` ## Bug - [x] Related issues linked using `fixes #number` - [x] Integration tests added - [ ] Errors have helpful link attached, see `contributing.md`
-
JJ Kasper authored
* Update renderOpts.dev handling and fix check * Update awaiting in load-components * extra arg * fix streaming case
-
Luis Alvarez D authored
-
Steven authored
-