Skip to content

Commit 5cf3118

Browse files
authored
Fixed the ParseResult type in @babel/core (#14333)
1 parent 2ce3e9f commit 5cf3118

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

packages/babel-core/src/parser/index.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,10 @@
11
import type { Handler } from "gensync";
22
import { parse } from "@babel/parser";
3-
import type * as t from "@babel/types";
43
import { codeFrameColumns } from "@babel/code-frame";
54
import generateMissingPluginMessage from "./util/missing-plugin-helper";
65
import type { PluginPasses } from "../config";
76

8-
type AstRoot = t.File | t.Program;
9-
10-
export type ParseResult = AstRoot;
7+
export type ParseResult = ReturnType<typeof parse>;
118

129
export default function* parser(
1310
pluginPasses: PluginPasses,

0 commit comments

Comments
 (0)