Skip to content

chore(babel): Remove .babelrc.js files#1398

Merged
Tobbe merged 2 commits intomainfrom
tobbe-remove-babelrc-files
Mar 18, 2026
Merged

chore(babel): Remove .babelrc.js files#1398
Tobbe merged 2 commits intomainfrom
tobbe-remove-babelrc-files

Conversation

@Tobbe
Copy link
Member

@Tobbe Tobbe commented Mar 18, 2026

Remove old unused babel config files.

@netlify
Copy link

netlify bot commented Mar 18, 2026

Deploy Preview for cedarjs canceled.

Name Link
🔨 Latest commit b92daf4
🔍 Latest deploy log https://app.netlify.com/projects/cedarjs/deploys/69ba83bf2f667c00089dd1ad

@Tobbe Tobbe changed the title Tobbe remove babelrc files chore(babel): Remove .babelrc.js files Mar 18, 2026
@greptile-apps
Copy link
Contributor

greptile-apps bot commented Mar 18, 2026

Greptile Summary

This PR removes 7 per-package .babelrc.js/.babelrc.cjs files that were previously used to extend the root babel.config.js for Jest. All affected packages (api-server, babel-config, gqlorm, graphql-server, realtime, router, web) have since migrated their test runners to Vitest, making these files dead configuration. The root babel.config.js remains in place and continues to serve build-time transpilation.

Key points:

  • All 7 deleted files were single-line (or two-line) shims: module.exports = { extends: '../../babel.config.js' }
  • Every affected package's test script now invokes vitest run, confirming Jest is no longer used in these packages
  • The packages/babel-config/.babelrc.js even contained an explicit comment: "Even though this package is built without Babel, we need this file for Jest." — further confirming the files were Jest-only
  • No build pipelines or runtime behaviour are affected; this is a pure dead-config cleanup

Confidence Score: 5/5

  • This PR is safe to merge — it removes only unused Jest-era Babel config files from packages that have fully migrated to Vitest.
  • All deleted files were identical one-liner shims whose sole purpose was Jest integration. Every affected package has already switched to Vitest, verified by their package.json test scripts. The root babel.config.js (which still handles builds) is untouched, and nx.json only references that root file. There is no risk of breaking tests, builds, or any other workflow.
  • No files require special attention.

Important Files Changed

Filename Overview
packages/api-server/.babelrc.js Deleted — was a one-liner extending the root babel.config.js for Jest; api-server now uses Vitest so this file was unused.
packages/babel-config/.babelrc.js Deleted — contained an explicit comment that it was only needed for Jest; babel-config has migrated to Vitest.
packages/gqlorm/.babelrc.cjs Deleted — CJS variant of the same Jest shim; gqlorm now uses Vitest.
packages/graphql-server/.babelrc.js Deleted — unused Jest babel shim; graphql-server now uses Vitest.
packages/realtime/.babelrc.js Deleted — unused Jest babel shim; realtime now uses Vitest.
packages/router/.babelrc.js Deleted — unused Jest babel shim; router now uses Vitest (a jest.config.js is still present but the test script is vitest run).
packages/web/.babelrc.js Deleted — unused Jest babel shim; web now uses Vitest.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Root babel.config.js] -->|extends| B[packages/api-server/.babelrc.js ❌ removed]
    A -->|extends| C[packages/babel-config/.babelrc.js ❌ removed]
    A -->|extends| D[packages/gqlorm/.babelrc.cjs ❌ removed]
    A -->|extends| E[packages/graphql-server/.babelrc.js ❌ removed]
    A -->|extends| F[packages/realtime/.babelrc.js ❌ removed]
    A -->|extends| G[packages/router/.babelrc.js ❌ removed]
    A -->|extends| H[packages/web/.babelrc.js ❌ removed]

    I[Jest - no longer used] -.->|previously required| B
    I -.->|previously required| C
    I -.->|previously required| D
    I -.->|previously required| E
    I -.->|previously required| F
    I -.->|previously required| G
    I -.->|previously required| H

    J[Vitest ✅ now used] --> K[All 7 packages]
    A -->|still used for builds| K
Loading

Last reviewed commit: "Merge branch 'main' ..."

@nx-cloud
Copy link

nx-cloud bot commented Mar 18, 2026

🤖 Nx Cloud AI Fix

Ensure the fix-ci command is configured to always run in your CI pipeline to get automatic fixes in future runs. For more information, please see https://nx.dev/ci/features/self-healing-ci


View your CI Pipeline Execution ↗ for commit b92daf4

Command Status Duration Result
nx run-many -t build:pack --exclude create-ceda... ✅ Succeeded 2s View ↗
nx run-many -t build ✅ Succeeded 1m 42s View ↗
nx run-many -t test --minWorkers=1 --maxWorkers=4 ✅ Succeeded 3m 10s View ↗
nx run-many -t test:types ✅ Succeeded 10s View ↗

☁️ Nx Cloud last updated this comment at 2026-03-18 11:13:22 UTC

@Tobbe Tobbe added the release:chore This PR is a chore (means nothing for users) label Mar 18, 2026
@Tobbe Tobbe added this to the next-release-patch milestone Mar 18, 2026
@Tobbe Tobbe merged commit 395f24d into main Mar 18, 2026
44 of 48 checks passed
@Tobbe Tobbe deleted the tobbe-remove-babelrc-files branch March 18, 2026 11:47
@github-actions
Copy link

The changes in this PR are now available on npm.

Try them out by running yarn cedar upgrade -t 3.0.0-canary.13610

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release:chore This PR is a chore (means nothing for users)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant