From 00991d8baacc77babaab4ceaac3ad2c4a79d5492 Mon Sep 17 00:00:00 2001 From: Asish Kumar Date: Wed, 11 Nov 2026 20:41:28 +0530 Subject: [PATCH 1/4] docs(cli): point Babel 8 users to @babel/build-external-helpers @babel/cli no longer ships bin/babel-external-helpers.js in Babel 8; the helper generator lives in @babel/build-external-helpers. Replace the outdated statement and update the example package.json versions to ^8.0.0. Fixes #3261 --- docs/cli.md | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/docs/cli.md b/docs/cli.md index 135f5324f8..075d14ffad 100644 --- a/docs/cli.md +++ b/docs/cli.md @@ -5,7 +5,11 @@ title: "@babel/cli" Babel comes with a built-in CLI which can be used to compile files from the command line. -In addition, various entry point scripts live in the top-level package at `@babel/cli/bin`. There is a shell-executable utility script, `babel-external-helpers.js`, and the main Babel cli script, `babel.js`. +The main Babel CLI script, `babel.js`, lives in the top-level package at `@babel/cli/bin`. + +:::note +In Babel 7, `@babel/cli/bin` also included a `babel-external-helpers.js` utility script. Starting from Babel 8, it has moved to a separate package: see [`@babel/build-external-helpers`](build-external-helpers.md). +::: ## Install @@ -34,8 +38,8 @@ After that finishes installing, your `package.json` file should include: ```diff { "devDependencies": { -+ "@babel/cli": "^7.0.0", -+ "@babel/core": "^7.0.0" ++ "@babel/cli": "^8.0.0", ++ "@babel/core": "^8.0.0" } } ``` From 4219b6645765f3a70e7b8309e44152af2aba4dd3 Mon Sep 17 00:00:00 2001 From: Asish Kumar Date: Wed, 11 Nov 2026 20:41:32 +0530 Subject: [PATCH 2/4] docs(cli): point Babel 8 users to @babel/build-external-helpers @babel/cli no longer ships bin/babel-external-helpers.js in Babel 8; the helper generator lives in @babel/build-external-helpers. Replace the outdated statement and update the example package.json versions to ^8.0.0. Fixes #3261 --- docs/cli.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/cli.md b/docs/cli.md index 075d14ffad..a8a6375811 100644 --- a/docs/cli.md +++ b/docs/cli.md @@ -8,7 +8,7 @@ Babel comes with a built-in CLI which can be used to compile files from the comm The main Babel CLI script, `babel.js`, lives in the top-level package at `@babel/cli/bin`. :::note -In Babel 7, `@babel/cli/bin` also included a `babel-external-helpers.js` utility script. Starting from Babel 8, it has moved to a separate package: see [`@babel/build-external-helpers`](build-external-helpers.md). +In Babel 7, `@babel/cli/bin` also included a `babel-external-helpers.js` utility script. Starting from Babel 8, it has moved to a separate package: see [`@babel/build-external-helpers`](./build-external-helpers.md). ::: ## Install From 3130bbe9aad8030c4b786f89d56fc46a5817b5d4 Mon Sep 17 00:00:00 2001 From: Asish Kumar Date: Sat, 14 Nov 2026 21:34:31 +0530 Subject: [PATCH 3/4] docs: move babel-external-helpers note to the v8 migration guide --- docs/cli.md | 4 ---- docs/v8-migration.md | 7 +++++++ 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/docs/cli.md b/docs/cli.md index a8a6375811..a18da15288 100644 --- a/docs/cli.md +++ b/docs/cli.md @@ -7,10 +7,6 @@ Babel comes with a built-in CLI which can be used to compile files from the comm The main Babel CLI script, `babel.js`, lives in the top-level package at `@babel/cli/bin`. -:::note -In Babel 7, `@babel/cli/bin` also included a `babel-external-helpers.js` utility script. Starting from Babel 8, it has moved to a separate package: see [`@babel/build-external-helpers`](./build-external-helpers.md). -::: - ## Install While you _can_ install Babel CLI globally on your machine, it's much better diff --git a/docs/v8-migration.md b/docs/v8-migration.md index cddf6d9077..6df6cff12e 100644 --- a/docs/v8-migration.md +++ b/docs/v8-migration.md @@ -856,6 +856,13 @@ Make sure to also check the [@babel/plugin-transform-flow-strip-types](#babel-pl } ``` +### `@babel/cli` {#babel-cli} + +![low](https://img.shields.io/badge/risk%20of%20breakage%3F-low-yellowgreen.svg) + +- The `babel-external-helpers.js` script in `@babel/cli/bin` has been moved to a separate package, [`@babel/build-external-helpers`](./build-external-helpers.md). + **Migration**: If you are running `@babel/cli/bin/babel-external-helpers.js`, install `@babel/build-external-helpers` and use it instead. + ### `@babel/node` {#babel-node} ![low](https://img.shields.io/badge/risk%20of%20breakage%3F-low-yellowgreen.svg) From e6c5e1cad3496a7efc8dae466390564a308d01b8 Mon Sep 17 00:00:00 2001 From: Asish Kumar Date: Sat, 14 Nov 2026 22:06:08 +0530 Subject: [PATCH 4/4] docs(v8-migration): expand babel-external-helpers entry with PR link and example --- docs/v8-migration.md | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/docs/v8-migration.md b/docs/v8-migration.md index 6df6cff12e..7f57daba76 100644 --- a/docs/v8-migration.md +++ b/docs/v8-migration.md @@ -860,8 +860,14 @@ Make sure to also check the [@babel/plugin-transform-flow-strip-types](#babel-pl ![low](https://img.shields.io/badge/risk%20of%20breakage%3F-low-yellowgreen.svg) -- The `babel-external-helpers.js` script in `@babel/cli/bin` has been moved to a separate package, [`@babel/build-external-helpers`](./build-external-helpers.md). - **Migration**: If you are running `@babel/cli/bin/babel-external-helpers.js`, install `@babel/build-external-helpers` and use it instead. +- `babel-external-helpers` has been moved from `@babel/cli` to a new package, [`@babel/build-external-helpers`](./build-external-helpers.md) ([#17746](https://github.com/babel/babel/pull/17746)). The `--whitelist` option has been removed in favor of `-l`/`--allowlist`. + + **Migration**: Install `@babel/build-external-helpers` and replace `babel-external-helpers` with `build-external-helpers` (or `npx @babel/build-external-helpers`): + + ```diff + - babel-external-helpers --whitelist createClass -t umd > helpers.js + + build-external-helpers --allowlist createClass -t umd > helpers.js + ``` ### `@babel/node` {#babel-node}