Commit Graph

17 Commits

Author SHA1 Message Date
Luke Sandberg a9cd6d7e45 Revert "Adopt pnpm catalogs for devDependencies" (#93226)
Reverts vercel/next.js#93071

This breaks our use of lerna, lerna uses npm-package-arg to parse
package.json files and cannot resolve `catalog` references
2026-04-24 16:18:08 -07:00
Luke Sandberg c52634747c Adopt pnpm catalogs for devDependencies (#93071)
### What?

Adopt pnpm [catalogs](https://pnpm.io/catalogs) for shared hoisted devDependencies: `typescript`, `jest`, `eslint`, and `prettier`. Each is pinned once in `pnpm-workspace.yaml` and referenced as `"<name>": "catalog:"` by every consumer.

Also adds the missing `dom.iterable` lib to `@next/routing`'s tsconfig, required by `URLSearchParams.entries()` in TypeScript 6.

### Why?

Several packages invoke these binaries in their build, test, or lint scripts but do not declare them in their own `devDependencies` — they rely on the hoisted root install.

This breaks Turborepo's cache invalidation: without a declared dep, a package has no lockfile edge to the tool, so bumping its version (e.g. #91257's TypeScript 5 → 6 upgrade) does not invalidate that package's task hash. `@next/routing`'s `types` task has been a remote-cache hit on canary since the TS 6 bump, even though it now fails locally on a cold cache — CI is replaying a stale pre-bump success.

The same latent hazard exists for `jest` (`@next/codemod`), `eslint` (`@next/bundle-analyzer-ui`), and `prettier` (`create-next-app`).

### How?

- `pnpm-workspace.yaml` defines `catalog:` entries for each tool.
- Consumer packages declare `"<name>": "catalog:"`. pnpm still hoists one copy, but each consumer now has a real lockfile edge to the resolved version.
- Root `package.json` migrates each pin to `"catalog:"` so the workspace file is the single source of truth.

Turborepo needs no changes — its existing per-package hashing picks up lockfile edge changes automatically. Future catalog bumps will invalidate every consumer's cache.

`@types/node` is a deliberate omission from this round: several packages intentionally pin different majors (`^22`, `^20`, `20.14.2`), so migrating it needs per-package intent review rather than bulk conversion.

<!-- NEXT_JS_LLM_PR -->
2026-04-21 11:53:42 -07:00
Luke Sandberg d4b051d92a Update next versions of internal apps (#92666)
Update next versions of internal apps

The `Deploy docs to Vercel` job is also broken at head

Fixes: VULN-7922
Fixes: VULN-7923
2026-04-14 09:07:00 -07:00
Sebastian "Sebbie" Silbermann d141874063 Bump TypeScript to 6.0 (#91257) 2026-04-14 12:22:38 +02:00
Tim Neutkens 6d82715d45 Fix swc wasm test on canary (#92738)
## What?

Fixes the failure of "test next-swc wasm" on the canary branch. The env
var it sets incorrectly propagated into the build process for the bundle
analyzer.

Example:
https://github.com/vercel/next.js/actions/runs/24352454644/job/71117953939

This makes sure that the env var is set to empty so that it is ignored
for that step specifically.

Ideally we'd figure out a more granular way to set this env var where it
is needed instead, but this unblocks the CI.
2026-04-14 10:57:14 +02:00
Sebastian "Sebbie" Silbermann c36d342725 [ci] Crash if next-swc could not be loaded when NEXT_TEST_NATIVE_DIR is specified (#90387) 2026-02-25 21:55:45 +01:00
Will Binns-Smith 39c6cbb208 bundle-analyzer: use <Select> and multiselect for top bar (#87254)
The top bar is getting quite wide with all of its button toggle groups.
This:

- Converts the Compressed/Uncompressed and Client/Server toggles to
shadcn `<Select>`s
- Adds a custom `<MultiSelect>` implementation since this is missing in
shadcn. This composes shadcn’s popovers and a series of checkboxes,
along with accessibility attributes and keyboard shortcuts.
- Uses this `<MultiSelect>` for the type filter
- Removes the divider between these since there aren’t any groups left
to divide

<img width="1547" height="719" alt="image"
src="https://github.com/user-attachments/assets/4041f6b7-2a47-4e17-b020-448ac0103740"
/>
2025-12-16 23:09:32 -08:00
Will Binns-Smith ec85895d74 bundle-analyzer: Show compressed sizes (#87093) 2025-12-16 05:49:54 +00:00
Sebastian "Sebbie" Silbermann 8479550bc5 Update installed Next.js (#87081) 2025-12-11 22:39:30 +01:00
Sebastian "Sebbie" Silbermann 51459c6f8a Update installed Next.js (#86822) 2025-12-04 15:15:23 +01:00
Zack Tanner a315d9fe32 Revert "add bundle analyzer as dev dependency to next (#86497)" (#86672)
I believe this is still breaking publishes. Reverts #86497
x-ref:
https://github.com/vercel/next.js/actions/runs/19790732218/job/56728905106
2025-11-30 20:23:23 +00:00
Tobias Koppers a1e2499574 add bundle analyzer as dev dependency to next (#86497)
### What?

We need to the dependency to make turborepo run the tasks in the correct order.
2025-11-27 13:36:25 +01:00
Zack Tanner 09c2f3c992 Revert "Turbopack: add bundle-analyzer to versioning and add dependen… (#86394)
…cy (#86355)"

This reverts commit 5b97f1f7b5.

Investigating if it fixes broken publishes.
2025-11-21 11:40:13 -08:00
Tobias Koppers e9a3ba935f Turbopack: fix import chain by determining depth locally per route (#86350)
### What?

fix the import chain showing only modules relevant to the current route

fix module graph being merged by path. It's keyed by identifier now.

also add more info to import chain, e. g. layer info. and more details in tooltip.
2025-11-21 11:39:18 +01:00
Tobias Koppers 5b97f1f7b5 Turbopack: add bundle-analyzer to versioning and add dependency (#86355)
### What?

fix lerna config and add dependency to make turborepo happy
2025-11-21 08:32:18 +01:00
Tobias Koppers f0a1a69a2b Turbopack: bundle-analyzer need to avoid using the local next.js build (#86258)
### What?

Next build breaks when the API doesn't match.
2025-11-20 12:36:39 +01:00
Will Binns-Smith 617ead5753 Turbopack: Add bundle analyzer UI to next build --experimental-analyze (#85788)
This adds an interactive Treemap-style bundle analyzer app to the Next.js codebase and writes a copy to disk when `next build --experimental-analyze` is run.

* It's a separate app in `apps/bundle-analyzer` as `@next/bundle-analyzer-ui` that uses `output: 'export'` to export a purely static Next.js app
* These static resources are copied into Next.js's published `dist` directory in the `next` package itself. Users never depend on `@next/bundle-analyzer-ui`
* When users run `next build --experimental-analyze`, these static resources are copied into the user's `.next/diagnostics/analyze` along with the data payloads needed to visualize the user's app

In an upcoming PR, we'll add `next experimental-analyze` that will create analysis files without build artifacts, as well as optionally start a static file server.

Test Plan: Ran `next build --experimental-analyze` in a test app and ran a static file server to run it.
2025-11-14 15:50:42 -08:00