[babel-types] Add extra property to BaseNode type (#12136)

This commit is contained in:
Ryan Rhee 2020-10-09 10:29:04 -04:00 committed by GitHub
parent f6bd7493a8
commit ebec7c8baf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

View File

@ -43,6 +43,7 @@ declare class ${NODE_PREFIX} {
start: ?number;
end: ?number;
loc: ?${NODE_PREFIX}SourceLocation;
extra?: { [string]: mixed };
}\n\n`;
//

View File

@ -45,6 +45,7 @@ interface BaseNode {
end: number | null;
loc: SourceLocation | null;
type: Node["type"];
extra?: Record<string, unknown>;
}
export type Node = ${t.TYPES.sort().join(" | ")};\n\n`;