Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
d238227
bump packages
AlessioGr Nov 3, 2025
0666056
bump dnd kit
AlessioGr Nov 3, 2025
a41cab2
fix: hydration error from dnd kit library
AlessioGr Nov 3, 2025
b64b871
fix
AlessioGr Nov 3, 2025
3b19cd3
perf: ensure pillselector draggablesortable does not remount multiple…
AlessioGr Nov 3, 2025
a953320
surpress hydration errors for now
AlessioGr Nov 3, 2025
0a9815f
chore: remove deprecated next config properties in monorepo
AlessioGr Nov 3, 2025
1412111
surpress more hydration errors
AlessioGr Nov 3, 2025
bf341c4
Fix HMR
AlessioGr Nov 3, 2025
690ed53
fix flaky test - page.reload was logging out the user
AlessioGr Nov 3, 2025
3a88243
Merge remote-tracking branch 'origin/main' into feat/next-16-support
AlessioGr Nov 3, 2025
75b0235
fix
AlessioGr Nov 4, 2025
e1d0052
Merge remote-tracking branch 'origin/main' into fix/next-16-hmr
AlessioGr Nov 4, 2025
6e3fdf1
update templates
AlessioGr Nov 4, 2025
725e24c
chore: regenerate lockfile
AlessioGr Nov 4, 2025
4dd9fa2
chore: fix build
AlessioGr Nov 4, 2025
d8b766a
fix turbopack error
AlessioGr Nov 4, 2025
2368473
Merge branch 'temptest' into feat/next-16-support
AlessioGr Nov 4, 2025
c496d57
lockfile
AlessioGr Nov 4, 2025
00702a2
templates: disable turbopack for build
AlessioGr Nov 5, 2025
b3b9771
Merge remote-tracking branch 'origin/main' into feat/next-16-support
AlessioGr Nov 5, 2025
ceb2515
fix lint
AlessioGr Nov 5, 2025
2edb1df
fix template tests in ci
AlessioGr Nov 5, 2025
0bf4b7f
fix(next): turbopack build support
AlessioGr Nov 5, 2025
f080567
Revert "templates: disable turbopack for build"
AlessioGr Nov 5, 2025
fb06d20
Merge remote-tracking branch 'origin/fix/turbo-bundle' into feat/next…
AlessioGr Nov 5, 2025
1f2656a
templates: fix revalidateTag
AlessioGr Nov 5, 2025
c34076e
chore: remove deprecated property in dev script
AlessioGr Nov 5, 2025
7423baf
templates: migrate lint scripts
AlessioGr Nov 5, 2025
605b578
chore: fix unit tests
AlessioGr Nov 5, 2025
149b1d8
templates: fix running e2e tests in ci
AlessioGr Nov 5, 2025
97555ba
fix payload cloud template ci
AlessioGr Nov 5, 2025
2163ac1
docs: update turbopack perf docs
AlessioGr Nov 5, 2025
ecaf240
attempt to fix flaky test
AlessioGr Nov 5, 2025
99c6f86
fix: sentry turbopack error
AlessioGr Nov 5, 2025
4e7ee37
chore: fix monorepo turbopack errors
AlessioGr Nov 5, 2025
50149c3
fix i18n test suite
AlessioGr Nov 5, 2025
7a4b51e
Merge remote-tracking branch 'origin/fix/turbo-bundle' into feat/next…
AlessioGr Nov 5, 2025
88a60dd
Merge remote-tracking branch 'origin/main' into feat/next-16-support
AlessioGr Nov 5, 2025
d882e48
regenerate templates
AlessioGr Nov 5, 2025
c5ce69a
perf: do not run hmr if reload already in progress
AlessioGr Nov 6, 2025
ef6ade2
fix nextjs 16 error
AlessioGr Nov 6, 2025
15444aa
Merge branch 'fix/hmr-turbo' into feat/next-16-support
AlessioGr Nov 6, 2025
342d6c1
Merge remote-tracking branch 'origin/main' into feat/next-16-support
AlessioGr Nov 6, 2025
6d4e534
templates
AlessioGr Nov 6, 2025
23abf20
Merge remote-tracking branch 'origin/main' into feat/next-16-support
AlessioGr Nov 7, 2025
e08967e
Merge remote-tracking branch 'origin/main' into feat/next-16-support
AlessioGr Nov 7, 2025
4d8e8de
chore: bump nextjs canary
AlessioGr Nov 12, 2025
4dab6ca
Merge remote-tracking branch 'origin/main' into feat/next-16-support
AlessioGr Nov 12, 2025
880d0fe
templates
AlessioGr Nov 13, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions docs/performance/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -206,11 +206,9 @@ Everything mentioned above applies to local development as well, but there are a

### Enable Turbopack

<Banner type="warning">
**Note:** In the future this will be the default. Use at your own risk.
</Banner>
In Next.js 16, turbopack is enabled by default, unless you explicitly disabled it using the `--webpack` flag.

Add `--turbo` to your dev script to significantly speed up your local development server start time.
In Next.js 15, add `--turbo` to your dev script to significantly speed up your local development server start time.

```json
{
Expand Down
1 change: 1 addition & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ const esModules = [
'@faceless-ui/window-info',
'@faceless-ui/modal',
'@faceless-ui/scroll-info',
'@borewit/text-codec',
].join('|')

import path from 'path'
Expand Down
1 change: 1 addition & 0 deletions next-env.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />
import './.next/dev/types/routes.d.ts'

// NOTE: This file should not be edited
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
9 changes: 5 additions & 4 deletions next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@ const withBundleAnalyzer = bundleAnalyzer({
const config = withBundleAnalyzer(
withPayload(
{
eslint: {
ignoreDuringBuilds: true,
},
typescript: {
ignoreBuildErrors: true,
},
Expand All @@ -42,7 +39,11 @@ const config = withBundleAnalyzer(
]
},
images: {
domains: ['localhost'],
remotePatterns: [
{
hostname: 'localhost',
},
],
},
webpack: (webpackConfig) => {
webpackConfig.resolve.extensionAlias = {
Expand Down
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@
"devDependencies": {
"@jest/globals": "29.7.0",
"@libsql/client": "0.14.0",
"@next/bundle-analyzer": "15.4.7",
"@next/bundle-analyzer": "16.0.2-canary.17",
"@payloadcms/db-postgres": "workspace:*",
"@payloadcms/eslint-config": "workspace:*",
"@payloadcms/eslint-plugin": "workspace:*",
Expand All @@ -153,8 +153,8 @@
"@types/jest": "29.5.12",
"@types/minimist": "1.2.5",
"@types/node": "22.15.30",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"@types/shelljs": "0.8.15",
"chalk": "^4.1.2",
"comment-json": "^4.2.3",
Expand All @@ -174,16 +174,16 @@
"lint-staged": "15.2.7",
"minimist": "1.2.8",
"mongodb-memory-server": "10.1.4",
"next": "15.4.7",
"mongoose": "8.15.1",
"next": "16.0.2-canary.17",
"open": "^10.1.0",
"p-limit": "^5.0.0",
"pg": "8.16.3",
"playwright": "1.56.1",
"playwright-core": "1.56.1",
"prettier": "3.5.3",
"react": "19.1.1",
"react-dom": "19.1.1",
"react": "19.2.0",
"react-dom": "19.2.0",
"rimraf": "6.0.1",
"sharp": "0.32.6",
"shelljs": "0.8.5",
Expand Down
4 changes: 2 additions & 2 deletions packages/admin-bar/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@
},
"devDependencies": {
"@payloadcms/eslint-config": "workspace:*",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"payload": "workspace:*"
},
"peerDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/live-preview-react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@
},
"devDependencies": {
"@payloadcms/eslint-config": "workspace:*",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"payload": "workspace:*"
},
"peerDependencies": {
Expand Down
10 changes: 5 additions & 5 deletions packages/next/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@
]
},
"dependencies": {
"@dnd-kit/core": "6.0.8",
"@dnd-kit/core": "6.3.1",
"@payloadcms/graphql": "workspace:*",
"@payloadcms/translations": "workspace:*",
"@payloadcms/ui": "workspace:*",
Expand All @@ -127,11 +127,11 @@
"@babel/preset-env": "7.27.2",
"@babel/preset-react": "7.27.1",
"@babel/preset-typescript": "7.27.1",
"@next/eslint-plugin-next": "15.4.7",
"@next/eslint-plugin-next": "16.0.2-canary.17",
"@payloadcms/eslint-config": "workspace:*",
"@types/busboy": "1.5.4",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"@types/uuid": "10.0.0",
"babel-plugin-react-compiler": "19.1.0-rc.3",
"esbuild": "0.25.5",
Expand All @@ -141,7 +141,7 @@
},
"peerDependencies": {
"graphql": "^16.8.1",
"next": "^15.2.3",
"next": "^15.2.3 || ^16.0.1",
"payload": "workspace:*"
},
"engines": {
Expand Down
39 changes: 28 additions & 11 deletions packages/payload/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1000,17 +1000,6 @@ export const reload = async (
})
}

// Generate import map
if (skipImportMapGeneration !== true && config.admin?.importMap?.autoGenerate !== false) {
// This may run outside of the admin panel, e.g. in the user's frontend, where we don't have an import map file.
// We don't want to throw an error in this case, as it would break the user's frontend.
// => just skip it => ignoreResolveError: true
await generateImportMap(config, {
ignoreResolveError: true,
log: true,
})
}

if (payload.db?.init) {
await payload.db.init()
}
Expand All @@ -1025,6 +1014,25 @@ export const reload = async (
;(global as any)._payload_doNotCacheClientConfig = true // This will help refreshing the client config cache more reliably. If you remove this, please test HMR + client config refreshing (do new fields appear in the document?)
;(global as any)._payload_doNotCacheSchemaMap = true
;(global as any)._payload_doNotCacheClientSchemaMap = true

// Generate import map
if (skipImportMapGeneration !== true && config.admin?.importMap?.autoGenerate !== false) {
// We need to run import map generation in the background, using setTimeout + a floating promise.
// Otherwise, in Next.js 16 and turbopack, the console will be spammed with errors that look like this:
// Error: Could not find the module "[project]/node_modules/.pnpm/[path-to-importmap-entry]" in the React Client Manifest. This is probably a bug in the React Server Components bundler.
// This will happen when running HMR for multiple getPayload calls, e.g. getPayload from admin panel and frontend.
// This usually happens for live-preview enabled collections.
// Once the generateImportMap accesses the import map file using fs, these errors will be thrown.
setTimeout(() => {
void generateImportMap(config, {
// This may run outside of the admin panel, e.g. in the user's frontend, where we don't have an import map file.
// We don't want to throw an error in this case, as it would break the user's frontend.
// => just skip it => ignoreResolveError: true
ignoreResolveError: true,
log: true,
})
}, 0)
}
}

let _cached: Map<
Expand Down Expand Up @@ -1116,6 +1124,7 @@ export const getPayload = async (
await reload(config, cached.payload, false, options)

resolve()
cached.reload = false
}

if (cached.reload instanceof Promise) {
Expand Down Expand Up @@ -1156,6 +1165,14 @@ export const getPayload = async (
)

cached.ws.onmessage = (event) => {
if (cached.reload instanceof Promise) {
// If there is an in-progress reload in the same getPayload
// cache instance, do not set reload to true again, which would
// trigger another reload.
// Instead, wait for the in-progress reload to finish.
return
}

if (typeof event.data === 'string') {
const data = JSON.parse(event.data)

Expand Down
4 changes: 2 additions & 2 deletions packages/plugin-cloud-storage/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@
},
"devDependencies": {
"@types/find-node-modules": "^2.1.2",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"payload": "workspace:*"
},
"peerDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/plugin-form-builder/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@
"devDependencies": {
"@payloadcms/eslint-config": "workspace:*",
"@types/escape-html": "^1.0.4",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"copyfiles": "^2.4.1",
"cross-env": "^7.0.3",
"payload": "workspace:*"
Expand Down
2 changes: 1 addition & 1 deletion packages/plugin-multi-tenant/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@
},
"peerDependencies": {
"@payloadcms/ui": "workspace:*",
"next": "^15.2.3",
"next": "^15.2.3 || ^16.0.1",
"payload": "workspace:*"
},
"publishConfig": {
Expand Down
4 changes: 2 additions & 2 deletions packages/plugin-search/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@
},
"devDependencies": {
"@payloadcms/eslint-config": "workspace:*",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"payload": "workspace:*"
},
"peerDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/plugin-sentry/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@
},
"devDependencies": {
"@payloadcms/eslint-config": "workspace:*",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"payload": "workspace:*"
},
"peerDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/plugin-seo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@
"devDependencies": {
"@payloadcms/eslint-config": "workspace:*",
"@payloadcms/next": "workspace:*",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"payload": "workspace:*"
},
"peerDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/plugin-stripe/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@
"@payloadcms/eslint-config": "workspace:*",
"@payloadcms/next": "workspace:*",
"@types/lodash.get": "^4.4.7",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"@types/uuid": "10.0.0",
"payload": "workspace:*"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/richtext-lexical/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -405,8 +405,8 @@
"@types/escape-html": "1.0.4",
"@types/json-schema": "7.0.15",
"@types/node": "22.15.30",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"babel-plugin-react-compiler": "19.1.0-rc.3",
"babel-plugin-transform-remove-imports": "^1.8.0",
"esbuild": "0.25.5",
Expand Down
1 change: 0 additions & 1 deletion packages/richtext-lexical/src/exports/server/ast/mdx.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ export function parseJSXToAST({
keepPositions?: boolean
}): AST {
const treeComplex: AST = fromMarkdown(jsxString, {
// @ts-expect-error
extensions: [mdxJsx({ acorn, addResult: false })],
mdastExtensions: [mdxJsxFromMarkdown()],
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,6 @@ function createTextFormatTransformersIndex(
fullMatchRegExpByTag,

// Regexp to locate *any* potential opening tag (longest first).
// eslint-disable-next-line regexp/no-useless-character-class, regexp/no-empty-capturing-group, regexp/no-empty-group
openTagsRegExp: new RegExp(`${escapeRegExp}(${openTagsRegExp.join('|')})`, 'g'),
transformersByTag,
}
Expand Down
4 changes: 2 additions & 2 deletions packages/richtext-slate/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@
"@payloadcms/eslint-config": "workspace:*",
"@types/is-hotkey": "^0.1.10",
"@types/node": "22.15.30",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"payload": "workspace:*"
},
"peerDependencies": {
Expand Down
1 change: 0 additions & 1 deletion packages/storage-s3/src/generateSignedURL.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ export const getGenerateSignedURLHandler = ({
const fileKey = path.posix.join(prefix, filename)

const url = await getSignedUrl(
// @ts-expect-error mismatch versions or something
getStorageClient(),
new AWS.PutObjectCommand({ ACL: acl, Bucket: bucket, ContentType: mimeType, Key: fileKey }),
{
Expand Down
5 changes: 2 additions & 3 deletions packages/storage-s3/src/staticHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ export const getHandler = ({
if (useSignedURL) {
const command = new GetObjectCommand({ Bucket: bucket, Key: key })
const signedUrl = await getSignedUrl(
// @ts-expect-error mismatch versions
getStorageClient(),
command,
typeof signedDownloads === 'object' ? signedDownloads : { expiresIn: 7200 },
Expand All @@ -115,9 +114,9 @@ export const getHandler = ({
// Only include Content-Length when it’s present and strictly numeric.
// This prevents "Parse Error: Invalid character in Content-Length" when providers (e.g., MinIO)
// return undefined or a non-numeric value.
const contentLength = String(object.ContentLength);
const contentLength = String(object.ContentLength)
if (contentLength && !isNaN(Number(contentLength))) {
headers.append('Content-Length', contentLength);
headers.append('Content-Length', contentLength)
}

headers.append('Content-Type', String(object.ContentType))
Expand Down
4 changes: 2 additions & 2 deletions packages/translations/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@
"devDependencies": {
"@payloadcms/eslint-config": "workspace:*",
"@swc/core": "1.11.29",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"dotenv": "16.4.7",
"prettier": "3.5.3",
"typescript": "5.7.3"
Expand Down
10 changes: 5 additions & 5 deletions packages/ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,8 @@
},
"dependencies": {
"@date-fns/tz": "1.2.0",
"@dnd-kit/core": "6.0.8",
"@dnd-kit/sortable": "7.0.2",
"@dnd-kit/core": "6.3.1",
"@dnd-kit/sortable": "10.0.0",
"@dnd-kit/utilities": "3.2.2",
"@faceless-ui/modal": "3.0.0",
"@faceless-ui/scroll-info": "2.0.0",
Expand Down Expand Up @@ -168,16 +168,16 @@
"@babel/preset-typescript": "7.27.1",
"@hyrious/esbuild-plugin-commonjs": "0.2.6",
"@payloadcms/eslint-config": "workspace:*",
"@types/react": "19.1.12",
"@types/react-dom": "19.1.9",
"@types/react": "19.2.2",
"@types/react-dom": "19.2.2",
"@types/uuid": "10.0.0",
"babel-plugin-react-compiler": "19.1.0-rc.3",
"esbuild": "0.25.5",
"esbuild-sass-plugin": "3.3.1",
"payload": "workspace:*"
},
"peerDependencies": {
"next": "^15.2.3",
"next": "^15.2.3 || ^16.0.1",
"payload": "workspace:*",
"react": "^19.0.0 || ^19.0.0-rc-65a56d0e-20241020",
"react-dom": "^19.0.0 || ^19.0.0-rc-65a56d0e-20241020"
Expand Down
Loading
Loading