Update Babel to v8 (#15157)

Co-authored-by: fisker <lionkay@gmail.com>
This commit is contained in:
Nicolò Ribaudoandfisker authored and GitHub committed 2025-09-24 10:31:22 +08:00
1 parent 21e98808a8
commit 6437b6dadf
26 files changed
+286 -280

No files matched your search

+1
View File
@@ -1,3 +1,4 @@
const colors = new Proxy(String, { get: () => colors });
export default colors;
export const createColors = () => colors;
+2 -3
View File
@@ -1,13 +1,11 @@
import path from "node:path";
import babelGenerator from "@babel/generator";
import generate from "@babel/generator";
import { parse } from "@babel/parser";
import { traverseFast as traverse } from "@babel/types";
import { outdent } from "outdent";
import { PROJECT_ROOT, SOURCE_DIR } from "../../utils/index.js";
import allTransforms from "./transforms/index.js";
const generate = babelGenerator.default;
/* Doesn't work for dependencies, optional call, computed property, and spread arguments */
function transform(original, file) {
@@ -20,6 +18,7 @@ function transform(original, file) {
) ||
file.startsWith(path.join(PROJECT_ROOT, "node_modules/jest-docblock/")) ||
file.startsWith(path.join(PROJECT_ROOT, "node_modules/espree/")) ||
file.startsWith(path.join(PROJECT_ROOT, "node_modules/@babel/parser/")) ||
file.startsWith(
path.join(
PROJECT_ROOT,