Skip to content

Commit 441ba9a

Browse files
committed
refactor(@angular/build): remove unneeded babel import attributes syntax plugin
As of babel v7.26.0, the separate `@babel/plugin-syntax-import-attributes` package is no longer needed. The ability to parse import attributes is included by default.
1 parent cccd35e commit 441ba9a

File tree

4 files changed

+1
-8
lines changed

4 files changed

+1
-8
lines changed

packages/angular/build/BUILD.bazel

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,6 @@ ts_project(
8181
":node_modules/@babel/core",
8282
":node_modules/@babel/helper-annotate-as-pure",
8383
":node_modules/@babel/helper-split-export-declaration",
84-
":node_modules/@babel/plugin-syntax-import-attributes",
8584
":node_modules/@inquirer/confirm",
8685
":node_modules/@vitejs/plugin-basic-ssl",
8786
":node_modules/browserslist",

packages/angular/build/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@
2323
"@babel/core": "7.26.10",
2424
"@babel/helper-annotate-as-pure": "7.25.9",
2525
"@babel/helper-split-export-declaration": "7.24.7",
26-
"@babel/plugin-syntax-import-attributes": "7.26.0",
2726
"@inquirer/confirm": "5.1.8",
2827
"@vitejs/plugin-basic-ssl": "2.0.0",
2928
"beasties": "0.2.0",

packages/angular/build/src/tools/esbuild/javascript-transformer-worker.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,7 @@ async function transformWithBabel(
6161
options.sourcemap &&
6262
(!!options.thirdPartySourcemaps || !/[\\/]node_modules[\\/]/.test(filename));
6363

64-
// @ts-expect-error Import attribute syntax plugin does not currently have type definitions
65-
const { default: importAttributePlugin } = await import('@babel/plugin-syntax-import-attributes');
66-
const plugins: PluginItem[] = [importAttributePlugin];
64+
const plugins: PluginItem[] = [];
6765

6866
if (options.instrumentForCoverage) {
6967
const { default: coveragePlugin } = await import('../babel/plugins/add-code-coverage.js');

pnpm-lock.yaml

Lines changed: 0 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)