Skip to content

[code-infra] Remove examples workspace and unused dependencies#21999

Merged
LukasTy merged 4 commits into
mui:masterfrom
LukasTy:claude/relaxed-tharp
Apr 7, 2026
Merged

[code-infra] Remove examples workspace and unused dependencies#21999
LukasTy merged 4 commits into
mui:masterfrom
LukasTy:claude/relaxed-tharp

Conversation

@LukasTy
Copy link
Copy Markdown
Member

@LukasTy LukasTy commented Apr 7, 2026

An effort to reduce the lock file bloat and hopefully prevent Renovate OOMs.

Changes

  • Remove examples workspace from pnpm configuration
    • The other example was already not picked up for workspace dependency install, since the apps are nested.
  • Remove unused dependencies from root package.json:
    • @types/requestidlecallback@0.3.7requestIdleCallback is in lib.dom since TS 4.4 and the only consumer (x-data-grid-generator/src/services/asyncWorker.ts) typechecks fine without it.
    • process@0.11.10 — only referenced inside @mui/monorepo/test/bundling/scripts/createTemplate.js, which mui-x never invokes.
  • Remove unused dependency from x-telemetry package:
    • @types/device-uuid@1.0.3
  • Add @mui/icons-material as explicit dev dependency to x-scheduler package to lock version to catalog
    • Without this, pnpm's autoInstallPeers was picking the lowest version matching the peer-dep range (^7.3.0 || ^9.0.0-beta.1), pulling an entire extra @mui/icons-material@7.3.9 projection into the lockfile and producing an unmet @mui/material@^7.3.9 peer warning.
  • Run pnpm dedupe to collapse duplicate vite@8.0.2-suffixed projections of @vitest/*, @vitejs/plugin-react{,-swc}, @codspeed/vitest-plugin, @mui/internal-test-utils, and @lerna/create into the existing vite@7.x projections used elsewhere in the workspace.
  • Update lockfile to reflect dependency changes.

Impact

Metric Before After Δ
pnpm-lock.yaml size 842 KB 813 KB -29 KB
pnpm-lock.yaml lines 24,859 24,282 -577
Versioned package entries 3,820 3,760 -60
Unique packages 1,937 1,919 -18

The line count is the most relevant number for Renovate's memory pressure — its pnpm parser walks the YAML graph during update planning, and the removed entries are mostly the v7/v8 @mui/* and vite@8 peer-dep projection trees.

Notable trees collapsed

  • Entire v7 @mui/* tree gone: @mui/material@7.3.9, @mui/system@7.3.9, @mui/utils@7.3.9, @mui/private-theming@7.3.9, @mui/styled-engine@7.3.9, @mui/icons-material@7.3.9 (last one fixed by the x-scheduler peer-dep change).
  • Entire v8 @mui/x-* tree gone: @mui/x-data-grid{,-pro,-premium}@8.27.0, @mui/x-internals@8.26.0, @mui/x-license@8.26.0, @mui/x-virtualizer@0.3.3, @mui/x-telemetry@8.20.0, @mui/x-internal-exceljs-fork@4.4.3.
  • Duplicate vite@8.0.2-suffixed projections of vitest/vitejs plugins gone (collapsed by pnpm dedupe).

Verification

Check Result
pnpm install --frozen-lockfile Pass
pnpm typescript (full monorepo, 23 projects) Pass
pnpm --filter @mui/x-data-grid-generator run typescript (the requestIdleCallback consumer) Pass
pnpm --filter @mui/x-telemetry run typescript Pass
pnpm test:unit --project x-telemetry --run Pass (60/60)
pnpm docs:build (Next.js webpack build + service worker) Pass

The pre-existing pnpm eslint errors in x-charts-premium/src/index.ts, x-charts-pro/src/index.ts, and x-data-grid/src/hooks/utils/index.ts (No named exports found in module …) and the pnpm docs:build link-check failure on [null](/x) both reproduce on master without any of the changes in this PR, so they are not regressions introduced here.

@LukasTy LukasTy added dependencies Update of dependencies. type: enhancement It’s an improvement, but we can’t make up our mind whether it's a bug fix or a new feature. labels Apr 7, 2026
@LukasTy LukasTy changed the title chore: remove examples workspace and unused dependencies [code-infra] Remove examples workspace and unused dependencies Apr 7, 2026
@mui-bot
Copy link
Copy Markdown

mui-bot commented Apr 7, 2026

Deploy preview: https://deploy-preview-21999--material-ui-x.netlify.app/

Bundle size report

Bundle Parsed size Gzip size
@mui/x-data-grid 0B(0.00%) 0B(0.00%)
@mui/x-data-grid-pro 0B(0.00%) 0B(0.00%)
@mui/x-data-grid-premium 0B(0.00%) 0B(0.00%)
@mui/x-charts 0B(0.00%) 0B(0.00%)
@mui/x-charts-pro 0B(0.00%) 0B(0.00%)
@mui/x-charts-premium 0B(0.00%) 0B(0.00%)
@mui/x-date-pickers 0B(0.00%) 0B(0.00%)
@mui/x-date-pickers-pro 0B(0.00%) 0B(0.00%)
@mui/x-tree-view 0B(0.00%) 0B(0.00%)
@mui/x-tree-view-pro 0B(0.00%) 0B(0.00%)

Details of bundle changes

Generated by 🚫 dangerJS against 68a794d

@LukasTy LukasTy removed the type: enhancement It’s an improvement, but we can’t make up our mind whether it's a bug fix or a new feature. label Apr 7, 2026
@LukasTy LukasTy requested review from a team and cherniavskii April 7, 2026 09:37
@LukasTy LukasTy merged commit 996f143 into mui:master Apr 7, 2026
23 of 24 checks passed
@LukasTy LukasTy deleted the claude/relaxed-tharp branch April 7, 2026 10:41
LukasTy added a commit to LukasTy/mui-x that referenced this pull request Apr 7, 2026
Follow-up on mui#21999. Reduces Renovate's per-PR memory pressure and
shrinks the lockfile churn for workspace edits.

- renovate.json: add `ignorePaths: ["**/bug-reproductions/**"]`. The
  mui-public preset already ignores `examples/`, but `bug-reproductions/`
  packages pin every dep to `"latest"`, so there is nothing for Renovate
  to do there.
- pnpm-workspace.yaml: hoist `@atlaskit/pragmatic-drag-and-drop`,
  `@base-ui/react`, `@mui/types`, `execa`, and `jsdom` into the catalog.
  Each of those was duplicated with the same pinned version across
  2-4 package.json files; moving them to the catalog removes the
  duplication and cuts per-package Renovate PRs.
- Drop `chai-dom` and `@types/chai-dom` from root devDeps. Both are
  already direct deps of `@mui/internal-test-utils`, so the matchers
  and type augmentation keep flowing in transitively. Also drop the
  stale `"chai-dom"` entry from `packages/x-virtualizer/tsconfig.json`
  (x-virtualizer has no tests at all; the entry was leftover cruft).

Deliberately NOT bumping `vite` / `vitest` / `@vitejs/plugin-react` in
the catalog: `@vitejs/plugin-react@5.2.0` changes how JSX is compiled
such that inner named function expressions lose the `2` suffix in
`ForwardRef(DataGrid2)` stack frames, which breaks
`reactMajor < 19` tests in layout.DataGrid, slots.DataGrid, and
TreeViewItemsPlugin. Keeping plugin-react pinned at `^5.1.4` via the
existing catalog entry preserves the X2 naming.
LukasTy added a commit to LukasTy/mui-x that referenced this pull request Apr 7, 2026
Follow-up on mui#21999. Reduces Renovate's per-PR memory pressure and
shrinks the lockfile churn for workspace edits.

- renovate.json: add `ignorePaths: ["**/bug-reproductions/**"]`. The
  mui-public preset already ignores `examples/`, but `bug-reproductions/`
  packages pin every dep to `"latest"`, so there is nothing for Renovate
  to do there.
- pnpm-workspace.yaml: hoist `@atlaskit/pragmatic-drag-and-drop`,
  `@base-ui/react`, `@mui/types`, `execa`, and `jsdom` into the catalog.
  Each was duplicated with the same pinned version across 2-4
  package.json files; moving them to the catalog removes the duplication
  and cuts per-package Renovate PRs.
- Bump vite / vitest / @vitest/* / @vitejs/plugin-react* in the catalog:
  `vite ^7.3.1 -> ^8.0.2`, `vitest ^4.0.18 -> ^4.1.3`,
  `@vitest/* ^4.0.18 -> ^4.1.3`, `@vitejs/plugin-react ^5.1.4 -> ^5.2.0`,
  `@vitejs/plugin-react-swc ^4.2.3 -> ^4.3.0`. Aligns with
  `@mui/internal-bundle-size-checker`, which already pulled `vite@8`
  into the tree, so without this bump any package.json edit cascaded
  the lockfile across ~36 peer-resolved sites.
- `@vitejs/plugin-react@5.2.0` changes JSX scope handling so that inner
  named function expressions lose the `2` suffix in
  `<ForwardRef(DataGrid2)>` / `<ForwardRef(GridOverlay2)>` /
  `<ForwardRef(TreeItem2)>` stack frames. Relax the `reactMajor < 19`
  assertions in `layout.DataGrid`, `slots.DataGrid`, and
  `TreeViewItemsPlugin` to a substring that matches both the old and
  new form, so tests pass across bundler versions.
- pnpm-workspace.yaml: add a `peerDependencyRules.allowedVersions` entry
  for `@codspeed/vitest-plugin>vite`. Codspeed has not published vite@8
  support yet, but it runs fine against it in `test/performance-charts`.
  Can be removed once codspeed ships a new release.
- Drop `chai-dom` and `@types/chai-dom` from root devDeps. Both are
  already direct deps of `@mui/internal-test-utils`, so the matchers
  and type augmentation keep flowing in transitively. Also drop the
  stale `"chai-dom"` entry from `packages/x-virtualizer/tsconfig.json`
  (x-virtualizer has no tests at all; the entry was leftover cruft).
LukasTy added a commit to LukasTy/mui-x that referenced this pull request Apr 7, 2026
Follow-up on mui#21999. Reduces Renovate's per-PR memory pressure and
shrinks the lockfile churn for workspace edits.

- renovate.json: add `ignorePaths: ["**/bug-reproductions/**"]`. The
  mui-public preset already ignores `examples/`, but `bug-reproductions/`
  packages pin every dep to `"latest"`, so there is nothing for Renovate
  to do there.
- pnpm-workspace.yaml: hoist `@atlaskit/pragmatic-drag-and-drop`,
  `@base-ui/react`, `@mui/types`, `execa`, and `jsdom` into the catalog.
  Each was duplicated with the same pinned version across 2-4
  package.json files; moving them to the catalog removes the duplication
  and cuts per-package Renovate PRs.
- Bump vite / vitest / @vitest/* / @vitejs/plugin-react* in the catalog:
  `vite ^7.3.1 -> ^8.0.2`, `vitest ^4.0.18 -> ^4.1.3`,
  `@vitest/* ^4.0.18 -> ^4.1.3`, `@vitejs/plugin-react ^5.1.4 -> ^5.2.0`,
  `@vitejs/plugin-react-swc ^4.2.3 -> ^4.3.0`. Aligns with
  `@mui/internal-bundle-size-checker`, which already pulled `vite@8`
  into the tree, so without this bump any package.json edit cascaded
  the lockfile across ~36 peer-resolved sites.
- `@vitejs/plugin-react@5.2.0` changes JSX scope handling so that inner
  named function expressions lose the `2` suffix in
  `<ForwardRef(DataGrid2)>` / `<ForwardRef(GridOverlay2)>` /
  `<ForwardRef(TreeItem2)>` stack frames. Relax the `reactMajor < 19`
  assertions in `layout.DataGrid`, `slots.DataGrid`, and
  `TreeViewItemsPlugin` to a substring that matches both the old and
  new form, so tests pass across bundler versions.
- pnpm-workspace.yaml: add a `peerDependencyRules.allowedVersions` entry
  for `@codspeed/vitest-plugin>vite`. Codspeed has not published vite@8
  support yet, but it runs fine against it in `test/performance-charts`.
  Can be removed once codspeed ships a new release.
- Drop `chai-dom` and `@types/chai-dom` from root devDeps. Both are
  already direct deps of `@mui/internal-test-utils`, so the matchers
  and type augmentation keep flowing in transitively. Also drop the
  stale `"chai-dom"` entry from `packages/x-virtualizer/tsconfig.json`
  (x-virtualizer has no tests at all; the entry was leftover cruft).
LukasTy added a commit to LukasTy/mui-x that referenced this pull request Apr 7, 2026
Follow-up on mui#21999. Reduces Renovate's per-PR memory pressure and
tightens the dependency graph.

- renovate.json: add `ignorePaths: ["**/bug-reproductions/**"]`. The
  mui-public preset already ignores `examples/`, but `bug-reproductions/`
  packages pin every dep to `"latest"`, so there is nothing for Renovate
  to do there.
- pnpm-workspace.yaml: hoist `@atlaskit/pragmatic-drag-and-drop`,
  `@base-ui/react`, `@mui/types`, `execa`, and `jsdom` into the catalog.
  Each was duplicated with the same pinned version across 2-4
  package.json files; moving them to the catalog removes the duplication
  and cuts per-package Renovate PRs.
- Drop `chai-dom` and `@types/chai-dom` from root devDeps. Both are
  already direct deps of `@mui/internal-test-utils`, so the matchers
  and type augmentation keep flowing in transitively. Also drop the
  stale `"chai-dom"` entry from `packages/x-virtualizer/tsconfig.json`
  (x-virtualizer has no tests at all; the entry was leftover cruft).
- Relax the `reactMajor < 19` assertions in `layout.DataGrid`,
  `slots.DataGrid`, and `TreeViewItemsPlugin` to a substring prefix.
  `@vitejs/plugin-react` 5.2+ changes JSX scope handling so the inner
  named function expression no longer gets a `2` suffix in the
  `<ForwardRef(DataGrid2)>` frame. The prefix match is forward
  compatible with both the current `ForwardRef(DataGrid2)` form and
  the future `ForwardRef(DataGrid)` form, so a future `vite` /
  `vitest` / `@vitejs/plugin-react` catalog bump won't need to touch
  these tests again.
arminmeh pushed a commit to arminmeh/mui-x that referenced this pull request Apr 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Update of dependencies.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants