def("JSXFragment"), // attr=<>
null // attr= or just attr
), defaults["null"]);
def("JSXIdentifier")
.bases("Identifier")
.build("name")
.field("name", String);
def("JSXNamespacedName")
.bases("Node")
.build("namespace", "name")
.field("namespace", def("JSXIdentifier"))
.field("name", def("JSXIdentifier"));
def("JSXMemberExpression")
.bases("MemberExpression")
.build("object", "property")
.field("object", or(def("JSXIdentifier"), def("JSXMemberExpression")))
.field("property", def("JSXIdentifier"))
.field("computed", Boolean, defaults.false);
const JSXElementName = or(
def("JSXIdentifier"),
def("JSXNamespacedName"),
def("JSXMemberExpression")
);
def("JSXSpreadAttribute")
.bases("Node")
.build("argument")
.field("argument", def("Expression"));
const JSXAttributes = [or(
def("JSXAttribute"),
def("JSXSpreadAttribute")
)];
def("JSXExpressionContainer")
.bases("Expression")
.build("expression")
.field("expression", or(def("Expression"), def("JSXEmptyExpression")));
const JSXChildren = [or(
def("JSXText"),
def("JSXExpressionContainer"),
def("JSXSpreadChild"),
def("JSXElement"),
def("JSXFragment"),
def("Literal") // Legacy: Esprima should return JSXText instead.
)];
def("JSXElement")
.bases("Expression")
.build("openingElement", "closingElement", "children")
.field("openingElement", def("JSXOpeningElement"))
.field("closingElement", or(def("JSXClosingElement"), null), defaults["null"])
.field("children", JSXChildren, defaults.emptyArray)
.field("name", JSXElementName, function (this: N.JSXElement) {
// Little-known fact: the `this` object inside a default function
// is none other than the partially-built object itself, and any
// fields initialized directly from builder function arguments
// (like openingElement, closingElement, and children) are
// guaranteed to be available.
return this.openingElement.name;
}, true) // hidden from traversal
.field("selfClosing", Boolean, function (this: N.JSXElement) {
return this.openingElement.selfClosing;
}, true) // hidden from traversal
.field("attributes", JSXAttributes, function (this: N.JSXElement) {
return this.openingElement.attributes;
}, true); // hidden from traversal
def("JSXOpeningElement")
.bases("Node")
.build("name", "attributes", "selfClosing")
.field("name", JSXElementName)
.field("attributes", JSXAttributes, defaults.emptyArray)
.field("selfClosing", Boolean, defaults["false"]);
def("JSXClosingElement")
.bases("Node")
.build("name")
.field("name", JSXElementName);
def("JSXFragment")
.bases("Expression")
.build("openingFragment", "closingFragment", "children")
.field("openingFragment", def("JSXOpeningFragment"))
.field("closingFragment", def("JSXClosingFragment"))
.field("children", JSXChildren, defaults.emptyArray);
def("JSXOpeningFragment")
.bases("Node")
.build();
def("JSXClosingFragment")
.bases("Node")
.build();
def("JSXText")
.bases("Literal")
.build("value", "raw")
.field("value", String)
.field("raw", String, function (this: N.JSXText) {
return this.value;
});
def("JSXEmptyExpression")
.bases("Node")
.build();
def("JSXSpreadChild")
.bases("Node")
.build("expression")
.field("expression", def("Expression"));
};
ast-types-0.15.2/def/operators/000077500000000000000000000000001415222403600163035ustar00rootroot00000000000000ast-types-0.15.2/def/operators/core.ts000066400000000000000000000006501415222403600176040ustar00rootroot00000000000000export default function () {
return {
BinaryOperators: [
"==", "!=", "===", "!==",
"<", "<=", ">", ">=",
"<<", ">>", ">>>",
"+", "-", "*", "/", "%",
"&",
"|", "^", "in",
"instanceof",
],
AssignmentOperators: [
"=", "+=", "-=", "*=", "/=", "%=",
"<<=", ">>=", ">>>=",
"|=", "^=", "&=",
],
LogicalOperators: [
"||", "&&",
],
};
}
ast-types-0.15.2/def/operators/es2016.ts000066400000000000000000000010411415222403600175670ustar00rootroot00000000000000import coreOpsDef from "./core";
export default function (fork: import("../../types").Fork) {
const result = fork.use(coreOpsDef);
// Exponentiation operators. Must run before BinaryOperators or
// AssignmentOperators are used (hence before fork.use(es6Def)).
// https://github.com/tc39/proposal-exponentiation-operator
if (result.BinaryOperators.indexOf("**") < 0) {
result.BinaryOperators.push("**");
}
if (result.AssignmentOperators.indexOf("**=") < 0) {
result.AssignmentOperators.push("**=");
}
return result;
}ast-types-0.15.2/def/operators/es2020.ts000066400000000000000000000005741415222403600175740ustar00rootroot00000000000000import es2016OpsDef from "./es2016";
export default function (fork: import("../../types").Fork) {
const result = fork.use(es2016OpsDef);
// Nullish coalescing. Must run before LogicalOperators is used.
// https://github.com/tc39/proposal-nullish-coalescing
if (result.LogicalOperators.indexOf("??") < 0) {
result.LogicalOperators.push("??");
}
return result;
}
ast-types-0.15.2/def/operators/es2021.ts000066400000000000000000000007541415222403600175750ustar00rootroot00000000000000import es2020OpsDef from "./es2020";
export default function (fork: import("../../types").Fork) {
const result = fork.use(es2020OpsDef);
// Logical assignment operators. Must run before AssignmentOperators is used.
// https://github.com/tc39/proposal-logical-assignment
result.LogicalOperators.forEach(op => {
const assignOp = op + "=";
if (result.AssignmentOperators.indexOf(assignOp) < 0) {
result.AssignmentOperators.push(assignOp);
}
});
return result;
}
ast-types-0.15.2/def/type-annotations.ts000066400000000000000000000033441415222403600201550ustar00rootroot00000000000000/**
* Type annotation defs shared between Flow and TypeScript.
* These defs could not be defined in ./flow.ts or ./typescript.ts directly
* because they use the same name.
*/
import { Fork } from "../types";
import typesPlugin from "../lib/types";
import sharedPlugin from "../lib/shared";
export default function (fork: Fork) {
var types = fork.use(typesPlugin);
var def = types.Type.def;
var or = types.Type.or;
var defaults = fork.use(sharedPlugin).defaults;
var TypeAnnotation = or(
def("TypeAnnotation"),
def("TSTypeAnnotation"),
null
);
var TypeParamDecl = or(
def("TypeParameterDeclaration"),
def("TSTypeParameterDeclaration"),
null
);
def("Identifier")
.field("typeAnnotation", TypeAnnotation, defaults["null"]);
def("ObjectPattern")
.field("typeAnnotation", TypeAnnotation, defaults["null"]);
def("Function")
.field("returnType", TypeAnnotation, defaults["null"])
.field("typeParameters", TypeParamDecl, defaults["null"]);
def("ClassProperty")
.build("key", "value", "typeAnnotation", "static")
.field("value", or(def("Expression"), null))
.field("static", Boolean, defaults["false"])
.field("typeAnnotation", TypeAnnotation, defaults["null"]);
["ClassDeclaration",
"ClassExpression",
].forEach(typeName => {
def(typeName)
.field("typeParameters", TypeParamDecl, defaults["null"])
.field("superTypeParameters",
or(def("TypeParameterInstantiation"),
def("TSTypeParameterInstantiation"),
null),
defaults["null"])
.field("implements",
or([def("ClassImplements")],
[def("TSExpressionWithTypeArguments")]),
defaults.emptyArray);
});
};
ast-types-0.15.2/def/typescript.ts000066400000000000000000000355411415222403600170530ustar00rootroot00000000000000import { Fork } from "../types";
import babelCoreDef from "./babel-core";
import typeAnnotationsDef from "./type-annotations";
import typesPlugin from "../lib/types";
import sharedPlugin from "../lib/shared";
export default function (fork: Fork) {
// Since TypeScript is parsed by Babylon, include the core Babylon types
// but omit the Flow-related types.
fork.use(babelCoreDef);
fork.use(typeAnnotationsDef);
var types = fork.use(typesPlugin);
var n = types.namedTypes;
var def = types.Type.def;
var or = types.Type.or;
var defaults = fork.use(sharedPlugin).defaults;
var StringLiteral = types.Type.from(function (value: any, deep?: any) {
if (n.StringLiteral &&
n.StringLiteral.check(value, deep)) {
return true
}
if (n.Literal &&
n.Literal.check(value, deep) &&
typeof value.value === "string") {
return true;
}
return false;
}, "StringLiteral");
def("TSType")
.bases("Node");
var TSEntityName = or(
def("Identifier"),
def("TSQualifiedName")
);
def("TSTypeReference")
.bases("TSType", "TSHasOptionalTypeParameterInstantiation")
.build("typeName", "typeParameters")
.field("typeName", TSEntityName);
// An abstract (non-buildable) base type that provide a commonly-needed
// optional .typeParameters field.
def("TSHasOptionalTypeParameterInstantiation")
.field("typeParameters",
or(def("TSTypeParameterInstantiation"), null),
defaults["null"]);
// An abstract (non-buildable) base type that provide a commonly-needed
// optional .typeParameters field.
def("TSHasOptionalTypeParameters")
.field("typeParameters",
or(def("TSTypeParameterDeclaration"), null, void 0),
defaults["null"]);
// An abstract (non-buildable) base type that provide a commonly-needed
// optional .typeAnnotation field.
def("TSHasOptionalTypeAnnotation")
.field("typeAnnotation",
or(def("TSTypeAnnotation"), null),
defaults["null"]);
def("TSQualifiedName")
.bases("Node")
.build("left", "right")
.field("left", TSEntityName)
.field("right", TSEntityName);
def("TSAsExpression")
.bases("Expression", "Pattern")
.build("expression", "typeAnnotation")
.field("expression", def("Expression"))
.field("typeAnnotation", def("TSType"))
.field("extra",
or({ parenthesized: Boolean }, null),
defaults["null"]);
def("TSNonNullExpression")
.bases("Expression", "Pattern")
.build("expression")
.field("expression", def("Expression"));
[ // Define all the simple keyword types.
"TSAnyKeyword",
"TSBigIntKeyword",
"TSBooleanKeyword",
"TSNeverKeyword",
"TSNullKeyword",
"TSNumberKeyword",
"TSObjectKeyword",
"TSStringKeyword",
"TSSymbolKeyword",
"TSUndefinedKeyword",
"TSUnknownKeyword",
"TSVoidKeyword",
"TSIntrinsicKeyword",
"TSThisType",
].forEach(keywordType => {
def(keywordType)
.bases("TSType")
.build();
});
def("TSArrayType")
.bases("TSType")
.build("elementType")
.field("elementType", def("TSType"))
def("TSLiteralType")
.bases("TSType")
.build("literal")
.field("literal",
or(def("NumericLiteral"),
def("StringLiteral"),
def("BooleanLiteral"),
def("TemplateLiteral"),
def("UnaryExpression")));
def("TemplateLiteral")
// The TemplateLiteral type appears to be reused for TypeScript template
// literal types (instead of introducing a new TSTemplateLiteralType type),
// so we allow the templateLiteral.expressions array to be either all
// expressions or all TypeScript types.
.field("expressions", or(
[def("Expression")],
[def("TSType")],
));
["TSUnionType",
"TSIntersectionType",
].forEach(typeName => {
def(typeName)
.bases("TSType")
.build("types")
.field("types", [def("TSType")]);
});
def("TSConditionalType")
.bases("TSType")
.build("checkType", "extendsType", "trueType", "falseType")
.field("checkType", def("TSType"))
.field("extendsType", def("TSType"))
.field("trueType", def("TSType"))
.field("falseType", def("TSType"));
def("TSInferType")
.bases("TSType")
.build("typeParameter")
.field("typeParameter", def("TSTypeParameter"));
def("TSParenthesizedType")
.bases("TSType")
.build("typeAnnotation")
.field("typeAnnotation", def("TSType"));
var ParametersType = [or(
def("Identifier"),
def("RestElement"),
def("ArrayPattern"),
def("ObjectPattern")
)];
["TSFunctionType",
"TSConstructorType",
].forEach(typeName => {
def(typeName)
.bases("TSType",
"TSHasOptionalTypeParameters",
"TSHasOptionalTypeAnnotation")
.build("parameters")
.field("parameters", ParametersType);
});
def("TSDeclareFunction")
.bases("Declaration", "TSHasOptionalTypeParameters")
.build("id", "params", "returnType")
.field("declare", Boolean, defaults["false"])
.field("async", Boolean, defaults["false"])
.field("generator", Boolean, defaults["false"])
.field("id", or(def("Identifier"), null), defaults["null"])
.field("params", [def("Pattern")])
// tSFunctionTypeAnnotationCommon
.field("returnType",
or(def("TSTypeAnnotation"),
def("Noop"), // Still used?
null),
defaults["null"]);
def("TSDeclareMethod")
.bases("Declaration", "TSHasOptionalTypeParameters")
.build("key", "params", "returnType")
.field("async", Boolean, defaults["false"])
.field("generator", Boolean, defaults["false"])
.field("params", [def("Pattern")])
// classMethodOrPropertyCommon
.field("abstract", Boolean, defaults["false"])
.field("accessibility",
or("public", "private", "protected", void 0),
defaults["undefined"])
.field("static", Boolean, defaults["false"])
.field("computed", Boolean, defaults["false"])
.field("optional", Boolean, defaults["false"])
.field("key", or(
def("Identifier"),
def("StringLiteral"),
def("NumericLiteral"),
// Only allowed if .computed is true.
def("Expression")
))
// classMethodOrDeclareMethodCommon
.field("kind",
or("get", "set", "method", "constructor"),
function getDefault() { return "method"; })
.field("access", // Not "accessibility"?
or("public", "private", "protected", void 0),
defaults["undefined"])
.field("decorators",
or([def("Decorator")], null),
defaults["null"])
// tSFunctionTypeAnnotationCommon
.field("returnType",
or(def("TSTypeAnnotation"),
def("Noop"), // Still used?
null),
defaults["null"]);
def("TSMappedType")
.bases("TSType")
.build("typeParameter", "typeAnnotation")
.field("readonly", or(Boolean, "+", "-"), defaults["false"])
.field("typeParameter", def("TSTypeParameter"))
.field("optional", or(Boolean, "+", "-"), defaults["false"])
.field("typeAnnotation",
or(def("TSType"), null),
defaults["null"]);
def("TSTupleType")
.bases("TSType")
.build("elementTypes")
.field("elementTypes", [or(
def("TSType"),
def("TSNamedTupleMember")
)]);
def("TSNamedTupleMember")
.bases("TSType")
.build("label", "elementType", "optional")
.field("label", def("Identifier"))
.field("optional", Boolean, defaults["false"])
.field("elementType", def("TSType"));
def("TSRestType")
.bases("TSType")
.build("typeAnnotation")
.field("typeAnnotation", def("TSType"));
def("TSOptionalType")
.bases("TSType")
.build("typeAnnotation")
.field("typeAnnotation", def("TSType"));
def("TSIndexedAccessType")
.bases("TSType")
.build("objectType", "indexType")
.field("objectType", def("TSType"))
.field("indexType", def("TSType"))
def("TSTypeOperator")
.bases("TSType")
.build("operator")
.field("operator", String)
.field("typeAnnotation", def("TSType"));
def("TSTypeAnnotation")
.bases("Node")
.build("typeAnnotation")
.field("typeAnnotation",
or(def("TSType"),
def("TSTypeAnnotation")));
def("TSIndexSignature")
.bases("Declaration", "TSHasOptionalTypeAnnotation")
.build("parameters", "typeAnnotation")
.field("parameters", [def("Identifier")]) // Length === 1
.field("readonly", Boolean, defaults["false"]);
def("TSPropertySignature")
.bases("Declaration", "TSHasOptionalTypeAnnotation")
.build("key", "typeAnnotation", "optional")
.field("key", def("Expression"))
.field("computed", Boolean, defaults["false"])
.field("readonly", Boolean, defaults["false"])
.field("optional", Boolean, defaults["false"])
.field("initializer",
or(def("Expression"), null),
defaults["null"]);
def("TSMethodSignature")
.bases("Declaration",
"TSHasOptionalTypeParameters",
"TSHasOptionalTypeAnnotation")
.build("key", "parameters", "typeAnnotation")
.field("key", def("Expression"))
.field("computed", Boolean, defaults["false"])
.field("optional", Boolean, defaults["false"])
.field("parameters", ParametersType);
def("TSTypePredicate")
.bases("TSTypeAnnotation", "TSType")
.build("parameterName", "typeAnnotation", "asserts")
.field("parameterName",
or(def("Identifier"),
def("TSThisType")))
.field("typeAnnotation", or(def("TSTypeAnnotation"), null),
defaults["null"])
.field("asserts", Boolean, defaults["false"]);
["TSCallSignatureDeclaration",
"TSConstructSignatureDeclaration",
].forEach(typeName => {
def(typeName)
.bases("Declaration",
"TSHasOptionalTypeParameters",
"TSHasOptionalTypeAnnotation")
.build("parameters", "typeAnnotation")
.field("parameters", ParametersType);
});
def("TSEnumMember")
.bases("Node")
.build("id", "initializer")
.field("id", or(def("Identifier"), StringLiteral))
.field("initializer",
or(def("Expression"), null),
defaults["null"]);
def("TSTypeQuery")
.bases("TSType")
.build("exprName")
.field("exprName", or(TSEntityName, def("TSImportType")));
// Inferred from Babylon's tsParseTypeMember method.
var TSTypeMember = or(
def("TSCallSignatureDeclaration"),
def("TSConstructSignatureDeclaration"),
def("TSIndexSignature"),
def("TSMethodSignature"),
def("TSPropertySignature")
);
def("TSTypeLiteral")
.bases("TSType")
.build("members")
.field("members", [TSTypeMember]);
def("TSTypeParameter")
.bases("Identifier")
.build("name", "constraint", "default")
.field("name", String)
.field("constraint", or(def("TSType"), void 0), defaults["undefined"])
.field("default", or(def("TSType"), void 0), defaults["undefined"]);
def("TSTypeAssertion")
.bases("Expression", "Pattern")
.build("typeAnnotation", "expression")
.field("typeAnnotation", def("TSType"))
.field("expression", def("Expression"))
.field("extra",
or({ parenthesized: Boolean }, null),
defaults["null"]);
def("TSTypeParameterDeclaration")
.bases("Declaration")
.build("params")
.field("params", [def("TSTypeParameter")]);
def("TSTypeParameterInstantiation")
.bases("Node")
.build("params")
.field("params", [def("TSType")]);
def("TSEnumDeclaration")
.bases("Declaration")
.build("id", "members")
.field("id", def("Identifier"))
.field("const", Boolean, defaults["false"])
.field("declare", Boolean, defaults["false"])
.field("members", [def("TSEnumMember")])
.field("initializer",
or(def("Expression"), null),
defaults["null"]);
def("TSTypeAliasDeclaration")
.bases("Declaration", "TSHasOptionalTypeParameters")
.build("id", "typeAnnotation")
.field("id", def("Identifier"))
.field("declare", Boolean, defaults["false"])
.field("typeAnnotation", def("TSType"));
def("TSModuleBlock")
.bases("Node")
.build("body")
.field("body", [def("Statement")]);
def("TSModuleDeclaration")
.bases("Declaration")
.build("id", "body")
.field("id", or(StringLiteral, TSEntityName))
.field("declare", Boolean, defaults["false"])
.field("global", Boolean, defaults["false"])
.field("body",
or(def("TSModuleBlock"),
def("TSModuleDeclaration"),
null),
defaults["null"]);
def("TSImportType")
.bases("TSType", "TSHasOptionalTypeParameterInstantiation")
.build("argument", "qualifier", "typeParameters")
.field("argument", StringLiteral)
.field("qualifier", or(TSEntityName, void 0), defaults["undefined"]);
def("TSImportEqualsDeclaration")
.bases("Declaration")
.build("id", "moduleReference")
.field("id", def("Identifier"))
.field("isExport", Boolean, defaults["false"])
.field("moduleReference",
or(TSEntityName,
def("TSExternalModuleReference")));
def("TSExternalModuleReference")
.bases("Declaration")
.build("expression")
.field("expression", StringLiteral);
def("TSExportAssignment")
.bases("Statement")
.build("expression")
.field("expression", def("Expression"));
def("TSNamespaceExportDeclaration")
.bases("Declaration")
.build("id")
.field("id", def("Identifier"));
def("TSInterfaceBody")
.bases("Node")
.build("body")
.field("body", [TSTypeMember]);
def("TSExpressionWithTypeArguments")
.bases("TSType", "TSHasOptionalTypeParameterInstantiation")
.build("expression", "typeParameters")
.field("expression", TSEntityName);
def("TSInterfaceDeclaration")
.bases("Declaration", "TSHasOptionalTypeParameters")
.build("id", "body")
.field("id", TSEntityName)
.field("declare", Boolean, defaults["false"])
.field("extends",
or([def("TSExpressionWithTypeArguments")], null),
defaults["null"])
.field("body", def("TSInterfaceBody"));
def("TSParameterProperty")
.bases("Pattern")
.build("parameter")
.field("accessibility",
or("public", "private", "protected", void 0),
defaults["undefined"])
.field("readonly", Boolean, defaults["false"])
.field("parameter", or(def("Identifier"),
def("AssignmentPattern")));
def("ClassProperty")
.field("access", // Not "accessibility"?
or("public", "private", "protected", void 0),
defaults["undefined"])
// Defined already in es6 and babel-core.
def("ClassBody")
.field("body", [or(
def("MethodDefinition"),
def("VariableDeclarator"),
def("ClassPropertyDefinition"),
def("ClassProperty"),
def("ClassPrivateProperty"),
def("ClassMethod"),
def("ClassPrivateMethod"),
// Just need to add these types:
def("TSDeclareMethod"),
TSTypeMember
)]);
};
ast-types-0.15.2/fork.ts000066400000000000000000000027271415222403600150500ustar00rootroot00000000000000import typesPlugin from "./lib/types";
import pathVisitorPlugin from "./lib/path-visitor";
import equivPlugin from "./lib/equiv";
import pathPlugin from "./lib/path";
import nodePathPlugin from "./lib/node-path";
import { Fork, Plugin } from "./types";
export default function (plugins: Plugin
[]) {
const fork = createFork();
const types = fork.use(typesPlugin);
plugins.forEach(fork.use);
types.finalize();
const PathVisitor = fork.use(pathVisitorPlugin);
return {
Type: types.Type,
builtInTypes: types.builtInTypes,
namedTypes: types.namedTypes,
builders: types.builders,
defineMethod: types.defineMethod,
getFieldNames: types.getFieldNames,
getFieldValue: types.getFieldValue,
eachField: types.eachField,
someField: types.someField,
getSupertypeNames: types.getSupertypeNames,
getBuilderName: types.getBuilderName,
astNodesAreEquivalent: fork.use(equivPlugin),
finalize: types.finalize,
Path: fork.use(pathPlugin),
NodePath: fork.use(nodePathPlugin),
PathVisitor,
use: fork.use,
visit: PathVisitor.visit,
};
};
function createFork(): Fork {
const used: Plugin[] = [];
const usedResult: unknown[] = [];
function use(plugin: Plugin): T {
var idx = used.indexOf(plugin);
if (idx === -1) {
idx = used.length;
used.push(plugin);
usedResult[idx] = plugin(fork);
}
return usedResult[idx] as T;
}
var fork: Fork = { use };
return fork;
}
ast-types-0.15.2/gen/000077500000000000000000000000001415222403600143005ustar00rootroot00000000000000ast-types-0.15.2/gen/builders.ts000066400000000000000000003462731415222403600165000ustar00rootroot00000000000000/* !!! THIS FILE WAS AUTO-GENERATED BY `npm run gen` !!! */
import * as K from "./kinds";
import { namedTypes } from "./namedTypes";
export interface FileBuilder {
(program: K.ProgramKind, name?: string | null): namedTypes.File;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name?: string | null,
program: K.ProgramKind
}
): namedTypes.File;
}
export interface ProgramBuilder {
(body: K.StatementKind[]): namedTypes.Program;
from(
params: {
body: K.StatementKind[],
comments?: K.CommentKind[] | null,
directives?: K.DirectiveKind[],
interpreter?: K.InterpreterDirectiveKind | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.Program;
}
export interface IdentifierBuilder {
(name: string): namedTypes.Identifier;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name: string,
optional?: boolean,
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null
}
): namedTypes.Identifier;
}
export interface BlockStatementBuilder {
(body: K.StatementKind[]): namedTypes.BlockStatement;
from(
params: {
body: K.StatementKind[],
comments?: K.CommentKind[] | null,
directives?: K.DirectiveKind[],
loc?: K.SourceLocationKind | null
}
): namedTypes.BlockStatement;
}
export interface EmptyStatementBuilder {
(): namedTypes.EmptyStatement;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.EmptyStatement;
}
export interface ExpressionStatementBuilder {
(expression: K.ExpressionKind): namedTypes.ExpressionStatement;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.ExpressionStatement;
}
export interface IfStatementBuilder {
(
test: K.ExpressionKind,
consequent: K.StatementKind,
alternate?: K.StatementKind | null
): namedTypes.IfStatement;
from(
params: {
alternate?: K.StatementKind | null,
comments?: K.CommentKind[] | null,
consequent: K.StatementKind,
loc?: K.SourceLocationKind | null,
test: K.ExpressionKind
}
): namedTypes.IfStatement;
}
export interface LabeledStatementBuilder {
(label: K.IdentifierKind, body: K.StatementKind): namedTypes.LabeledStatement;
from(
params: {
body: K.StatementKind,
comments?: K.CommentKind[] | null,
label: K.IdentifierKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.LabeledStatement;
}
export interface BreakStatementBuilder {
(label?: K.IdentifierKind | null): namedTypes.BreakStatement;
from(
params: {
comments?: K.CommentKind[] | null,
label?: K.IdentifierKind | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.BreakStatement;
}
export interface ContinueStatementBuilder {
(label?: K.IdentifierKind | null): namedTypes.ContinueStatement;
from(
params: {
comments?: K.CommentKind[] | null,
label?: K.IdentifierKind | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ContinueStatement;
}
export interface WithStatementBuilder {
(object: K.ExpressionKind, body: K.StatementKind): namedTypes.WithStatement;
from(
params: {
body: K.StatementKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
object: K.ExpressionKind
}
): namedTypes.WithStatement;
}
export interface SwitchStatementBuilder {
(
discriminant: K.ExpressionKind,
cases: K.SwitchCaseKind[],
lexical?: boolean
): namedTypes.SwitchStatement;
from(
params: {
cases: K.SwitchCaseKind[],
comments?: K.CommentKind[] | null,
discriminant: K.ExpressionKind,
lexical?: boolean,
loc?: K.SourceLocationKind | null
}
): namedTypes.SwitchStatement;
}
export interface SwitchCaseBuilder {
(test: K.ExpressionKind | null, consequent: K.StatementKind[]): namedTypes.SwitchCase;
from(
params: {
comments?: K.CommentKind[] | null,
consequent: K.StatementKind[],
loc?: K.SourceLocationKind | null,
test: K.ExpressionKind | null
}
): namedTypes.SwitchCase;
}
export interface ReturnStatementBuilder {
(argument: K.ExpressionKind | null): namedTypes.ReturnStatement;
from(
params: {
argument: K.ExpressionKind | null,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ReturnStatement;
}
export interface ThrowStatementBuilder {
(argument: K.ExpressionKind): namedTypes.ThrowStatement;
from(
params: {
argument: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ThrowStatement;
}
export interface TryStatementBuilder {
(
block: K.BlockStatementKind,
handler?: K.CatchClauseKind | null,
finalizer?: K.BlockStatementKind | null
): namedTypes.TryStatement;
from(
params: {
block: K.BlockStatementKind,
comments?: K.CommentKind[] | null,
finalizer?: K.BlockStatementKind | null,
guardedHandlers?: K.CatchClauseKind[],
handler?: K.CatchClauseKind | null,
handlers?: K.CatchClauseKind[],
loc?: K.SourceLocationKind | null
}
): namedTypes.TryStatement;
}
export interface CatchClauseBuilder {
(
param: K.PatternKind | null | undefined,
guard: K.ExpressionKind | null | undefined,
body: K.BlockStatementKind
): namedTypes.CatchClause;
from(
params: {
body: K.BlockStatementKind,
comments?: K.CommentKind[] | null,
guard?: K.ExpressionKind | null,
loc?: K.SourceLocationKind | null,
param?: K.PatternKind | null
}
): namedTypes.CatchClause;
}
export interface WhileStatementBuilder {
(test: K.ExpressionKind, body: K.StatementKind): namedTypes.WhileStatement;
from(
params: {
body: K.StatementKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
test: K.ExpressionKind
}
): namedTypes.WhileStatement;
}
export interface DoWhileStatementBuilder {
(body: K.StatementKind, test: K.ExpressionKind): namedTypes.DoWhileStatement;
from(
params: {
body: K.StatementKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
test: K.ExpressionKind
}
): namedTypes.DoWhileStatement;
}
export interface ForStatementBuilder {
(
init: K.VariableDeclarationKind | K.ExpressionKind | null,
test: K.ExpressionKind | null,
update: K.ExpressionKind | null,
body: K.StatementKind
): namedTypes.ForStatement;
from(
params: {
body: K.StatementKind,
comments?: K.CommentKind[] | null,
init: K.VariableDeclarationKind | K.ExpressionKind | null,
loc?: K.SourceLocationKind | null,
test: K.ExpressionKind | null,
update: K.ExpressionKind | null
}
): namedTypes.ForStatement;
}
export interface VariableDeclarationBuilder {
(
kind: "var" | "let" | "const",
declarations: (K.VariableDeclaratorKind | K.IdentifierKind)[]
): namedTypes.VariableDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
declarations: (K.VariableDeclaratorKind | K.IdentifierKind)[],
kind: "var" | "let" | "const",
loc?: K.SourceLocationKind | null
}
): namedTypes.VariableDeclaration;
}
export interface ForInStatementBuilder {
(
left: K.VariableDeclarationKind | K.ExpressionKind,
right: K.ExpressionKind,
body: K.StatementKind
): namedTypes.ForInStatement;
from(
params: {
body: K.StatementKind,
comments?: K.CommentKind[] | null,
left: K.VariableDeclarationKind | K.ExpressionKind,
loc?: K.SourceLocationKind | null,
right: K.ExpressionKind
}
): namedTypes.ForInStatement;
}
export interface DebuggerStatementBuilder {
(): namedTypes.DebuggerStatement;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.DebuggerStatement;
}
export interface FunctionDeclarationBuilder {
(
id: K.IdentifierKind | null,
params: K.PatternKind[],
body: K.BlockStatementKind,
generator?: boolean,
expression?: boolean
): namedTypes.FunctionDeclaration;
from(
params: {
async?: boolean,
body: K.BlockStatementKind,
comments?: K.CommentKind[] | null,
defaults?: (K.ExpressionKind | null)[],
expression?: boolean,
generator?: boolean,
id: K.IdentifierKind | null,
loc?: K.SourceLocationKind | null,
params: K.PatternKind[],
predicate?: K.FlowPredicateKind | null,
rest?: K.IdentifierKind | null,
returnType?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null,
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null
}
): namedTypes.FunctionDeclaration;
}
export interface FunctionExpressionBuilder {
(
id: K.IdentifierKind | null | undefined,
params: K.PatternKind[],
body: K.BlockStatementKind,
generator?: boolean,
expression?: boolean
): namedTypes.FunctionExpression;
from(
params: {
async?: boolean,
body: K.BlockStatementKind,
comments?: K.CommentKind[] | null,
defaults?: (K.ExpressionKind | null)[],
expression?: boolean,
generator?: boolean,
id?: K.IdentifierKind | null,
loc?: K.SourceLocationKind | null,
params: K.PatternKind[],
predicate?: K.FlowPredicateKind | null,
rest?: K.IdentifierKind | null,
returnType?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null,
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null
}
): namedTypes.FunctionExpression;
}
export interface VariableDeclaratorBuilder {
(id: K.PatternKind, init?: K.ExpressionKind | null): namedTypes.VariableDeclarator;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.PatternKind,
init?: K.ExpressionKind | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.VariableDeclarator;
}
export interface ThisExpressionBuilder {
(): namedTypes.ThisExpression;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ThisExpression;
}
export interface ArrayExpressionBuilder {
(
elements: (K.ExpressionKind | K.SpreadElementKind | K.RestElementKind | null)[]
): namedTypes.ArrayExpression;
from(
params: {
comments?: K.CommentKind[] | null,
elements: (K.ExpressionKind | K.SpreadElementKind | K.RestElementKind | null)[],
loc?: K.SourceLocationKind | null
}
): namedTypes.ArrayExpression;
}
export interface ObjectExpressionBuilder {
(
properties: (K.PropertyKind | K.ObjectMethodKind | K.ObjectPropertyKind | K.SpreadPropertyKind | K.SpreadElementKind)[]
): namedTypes.ObjectExpression;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
properties: (K.PropertyKind | K.ObjectMethodKind | K.ObjectPropertyKind | K.SpreadPropertyKind | K.SpreadElementKind)[]
}
): namedTypes.ObjectExpression;
}
export interface PropertyBuilder {
(
kind: "init" | "get" | "set",
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
value: K.ExpressionKind | K.PatternKind
): namedTypes.Property;
from(
params: {
comments?: K.CommentKind[] | null,
computed?: boolean,
decorators?: K.DecoratorKind[] | null,
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
kind: "init" | "get" | "set",
loc?: K.SourceLocationKind | null,
method?: boolean,
shorthand?: boolean,
value: K.ExpressionKind | K.PatternKind
}
): namedTypes.Property;
}
export interface LiteralBuilder {
(value: string | boolean | null | number | RegExp | BigInt): namedTypes.Literal;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
value: string | boolean | null | number | RegExp | BigInt
}
): namedTypes.Literal;
}
export interface SequenceExpressionBuilder {
(expressions: K.ExpressionKind[]): namedTypes.SequenceExpression;
from(
params: {
comments?: K.CommentKind[] | null,
expressions: K.ExpressionKind[],
loc?: K.SourceLocationKind | null
}
): namedTypes.SequenceExpression;
}
export interface UnaryExpressionBuilder {
(
operator: "-" | "+" | "!" | "~" | "typeof" | "void" | "delete",
argument: K.ExpressionKind,
prefix?: boolean
): namedTypes.UnaryExpression;
from(
params: {
argument: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
operator: "-" | "+" | "!" | "~" | "typeof" | "void" | "delete",
prefix?: boolean
}
): namedTypes.UnaryExpression;
}
export interface BinaryExpressionBuilder {
(
operator: "==" | "!=" | "===" | "!==" | "<" | "<=" | ">" | ">=" | "<<" | ">>" | ">>>" | "+" | "-" | "*" | "/" | "%" | "&" | "|" | "^" | "in" | "instanceof" | "**",
left: K.ExpressionKind,
right: K.ExpressionKind
): namedTypes.BinaryExpression;
from(
params: {
comments?: K.CommentKind[] | null,
left: K.ExpressionKind,
loc?: K.SourceLocationKind | null,
operator: "==" | "!=" | "===" | "!==" | "<" | "<=" | ">" | ">=" | "<<" | ">>" | ">>>" | "+" | "-" | "*" | "/" | "%" | "&" | "|" | "^" | "in" | "instanceof" | "**",
right: K.ExpressionKind
}
): namedTypes.BinaryExpression;
}
export interface AssignmentExpressionBuilder {
(
operator: "=" | "+=" | "-=" | "*=" | "/=" | "%=" | "<<=" | ">>=" | ">>>=" | "|=" | "^=" | "&=" | "**=" | "||=" | "&&=" | "??=",
left: K.PatternKind | K.MemberExpressionKind,
right: K.ExpressionKind
): namedTypes.AssignmentExpression;
from(
params: {
comments?: K.CommentKind[] | null,
left: K.PatternKind | K.MemberExpressionKind,
loc?: K.SourceLocationKind | null,
operator: "=" | "+=" | "-=" | "*=" | "/=" | "%=" | "<<=" | ">>=" | ">>>=" | "|=" | "^=" | "&=" | "**=" | "||=" | "&&=" | "??=",
right: K.ExpressionKind
}
): namedTypes.AssignmentExpression;
}
export interface MemberExpressionBuilder {
(
object: K.ExpressionKind,
property: K.IdentifierKind | K.ExpressionKind,
computed?: boolean
): namedTypes.MemberExpression;
from(
params: {
comments?: K.CommentKind[] | null,
computed?: boolean,
loc?: K.SourceLocationKind | null,
object: K.ExpressionKind,
optional?: boolean,
property: K.IdentifierKind | K.ExpressionKind
}
): namedTypes.MemberExpression;
}
export interface UpdateExpressionBuilder {
(operator: "++" | "--", argument: K.ExpressionKind, prefix: boolean): namedTypes.UpdateExpression;
from(
params: {
argument: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
operator: "++" | "--",
prefix: boolean
}
): namedTypes.UpdateExpression;
}
export interface LogicalExpressionBuilder {
(
operator: "||" | "&&" | "??",
left: K.ExpressionKind,
right: K.ExpressionKind
): namedTypes.LogicalExpression;
from(
params: {
comments?: K.CommentKind[] | null,
left: K.ExpressionKind,
loc?: K.SourceLocationKind | null,
operator: "||" | "&&" | "??",
right: K.ExpressionKind
}
): namedTypes.LogicalExpression;
}
export interface ConditionalExpressionBuilder {
(
test: K.ExpressionKind,
consequent: K.ExpressionKind,
alternate: K.ExpressionKind
): namedTypes.ConditionalExpression;
from(
params: {
alternate: K.ExpressionKind,
comments?: K.CommentKind[] | null,
consequent: K.ExpressionKind,
loc?: K.SourceLocationKind | null,
test: K.ExpressionKind
}
): namedTypes.ConditionalExpression;
}
export interface NewExpressionBuilder {
(
callee: K.ExpressionKind,
argumentsParam: (K.ExpressionKind | K.SpreadElementKind)[]
): namedTypes.NewExpression;
from(
params: {
arguments: (K.ExpressionKind | K.SpreadElementKind)[],
callee: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeArguments?: null | K.TypeParameterInstantiationKind
}
): namedTypes.NewExpression;
}
export interface CallExpressionBuilder {
(
callee: K.ExpressionKind,
argumentsParam: (K.ExpressionKind | K.SpreadElementKind)[]
): namedTypes.CallExpression;
from(
params: {
arguments: (K.ExpressionKind | K.SpreadElementKind)[],
callee: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
optional?: boolean,
typeArguments?: null | K.TypeParameterInstantiationKind
}
): namedTypes.CallExpression;
}
export interface RestElementBuilder {
(argument: K.PatternKind): namedTypes.RestElement;
from(
params: {
argument: K.PatternKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null
}
): namedTypes.RestElement;
}
export interface TypeAnnotationBuilder {
(typeAnnotation: K.FlowTypeKind): namedTypes.TypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.FlowTypeKind
}
): namedTypes.TypeAnnotation;
}
export interface TSTypeAnnotationBuilder {
(typeAnnotation: K.TSTypeKind | K.TSTypeAnnotationKind): namedTypes.TSTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.TSTypeKind | K.TSTypeAnnotationKind
}
): namedTypes.TSTypeAnnotation;
}
export interface SpreadElementPatternBuilder {
(argument: K.PatternKind): namedTypes.SpreadElementPattern;
from(
params: {
argument: K.PatternKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.SpreadElementPattern;
}
export interface ArrowFunctionExpressionBuilder {
(
params: K.PatternKind[],
body: K.BlockStatementKind | K.ExpressionKind,
expression?: boolean
): namedTypes.ArrowFunctionExpression;
from(
params: {
async?: boolean,
body: K.BlockStatementKind | K.ExpressionKind,
comments?: K.CommentKind[] | null,
defaults?: (K.ExpressionKind | null)[],
expression?: boolean,
generator?: false,
id?: null,
loc?: K.SourceLocationKind | null,
params: K.PatternKind[],
predicate?: K.FlowPredicateKind | null,
rest?: K.IdentifierKind | null,
returnType?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null,
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null
}
): namedTypes.ArrowFunctionExpression;
}
export interface ForOfStatementBuilder {
(
left: K.VariableDeclarationKind | K.PatternKind,
right: K.ExpressionKind,
body: K.StatementKind
): namedTypes.ForOfStatement;
from(
params: {
await?: boolean,
body: K.StatementKind,
comments?: K.CommentKind[] | null,
left: K.VariableDeclarationKind | K.PatternKind,
loc?: K.SourceLocationKind | null,
right: K.ExpressionKind
}
): namedTypes.ForOfStatement;
}
export interface YieldExpressionBuilder {
(argument: K.ExpressionKind | null, delegate?: boolean): namedTypes.YieldExpression;
from(
params: {
argument: K.ExpressionKind | null,
comments?: K.CommentKind[] | null,
delegate?: boolean,
loc?: K.SourceLocationKind | null
}
): namedTypes.YieldExpression;
}
export interface GeneratorExpressionBuilder {
(
body: K.ExpressionKind,
blocks: K.ComprehensionBlockKind[],
filter: K.ExpressionKind | null
): namedTypes.GeneratorExpression;
from(
params: {
blocks: K.ComprehensionBlockKind[],
body: K.ExpressionKind,
comments?: K.CommentKind[] | null,
filter: K.ExpressionKind | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.GeneratorExpression;
}
export interface ComprehensionBlockBuilder {
(left: K.PatternKind, right: K.ExpressionKind, each: boolean): namedTypes.ComprehensionBlock;
from(
params: {
comments?: K.CommentKind[] | null,
each: boolean,
left: K.PatternKind,
loc?: K.SourceLocationKind | null,
right: K.ExpressionKind
}
): namedTypes.ComprehensionBlock;
}
export interface ComprehensionExpressionBuilder {
(
body: K.ExpressionKind,
blocks: K.ComprehensionBlockKind[],
filter: K.ExpressionKind | null
): namedTypes.ComprehensionExpression;
from(
params: {
blocks: K.ComprehensionBlockKind[],
body: K.ExpressionKind,
comments?: K.CommentKind[] | null,
filter: K.ExpressionKind | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ComprehensionExpression;
}
export interface ObjectPropertyBuilder {
(
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
value: K.ExpressionKind | K.PatternKind
): namedTypes.ObjectProperty;
from(
params: {
accessibility?: K.LiteralKind | null,
comments?: K.CommentKind[] | null,
computed?: boolean,
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
loc?: K.SourceLocationKind | null,
shorthand?: boolean,
value: K.ExpressionKind | K.PatternKind
}
): namedTypes.ObjectProperty;
}
export interface PropertyPatternBuilder {
(
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
pattern: K.PatternKind
): namedTypes.PropertyPattern;
from(
params: {
comments?: K.CommentKind[] | null,
computed?: boolean,
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
loc?: K.SourceLocationKind | null,
pattern: K.PatternKind
}
): namedTypes.PropertyPattern;
}
export interface ObjectPatternBuilder {
(
properties: (K.PropertyKind | K.PropertyPatternKind | K.SpreadPropertyPatternKind | K.SpreadPropertyKind | K.ObjectPropertyKind | K.RestPropertyKind)[]
): namedTypes.ObjectPattern;
from(
params: {
comments?: K.CommentKind[] | null,
decorators?: K.DecoratorKind[] | null,
loc?: K.SourceLocationKind | null,
properties: (K.PropertyKind | K.PropertyPatternKind | K.SpreadPropertyPatternKind | K.SpreadPropertyKind | K.ObjectPropertyKind | K.RestPropertyKind)[],
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null
}
): namedTypes.ObjectPattern;
}
export interface ArrayPatternBuilder {
(elements: (K.PatternKind | K.SpreadElementKind | null)[]): namedTypes.ArrayPattern;
from(
params: {
comments?: K.CommentKind[] | null,
elements: (K.PatternKind | K.SpreadElementKind | null)[],
loc?: K.SourceLocationKind | null
}
): namedTypes.ArrayPattern;
}
export interface SpreadElementBuilder {
(argument: K.ExpressionKind): namedTypes.SpreadElement;
from(
params: {
argument: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.SpreadElement;
}
export interface AssignmentPatternBuilder {
(left: K.PatternKind, right: K.ExpressionKind): namedTypes.AssignmentPattern;
from(
params: {
comments?: K.CommentKind[] | null,
left: K.PatternKind,
loc?: K.SourceLocationKind | null,
right: K.ExpressionKind
}
): namedTypes.AssignmentPattern;
}
export interface MethodDefinitionBuilder {
(
kind: "constructor" | "method" | "get" | "set",
key: K.ExpressionKind,
value: K.FunctionKind,
staticParam?: boolean
): namedTypes.MethodDefinition;
from(
params: {
comments?: K.CommentKind[] | null,
computed?: boolean,
decorators?: K.DecoratorKind[] | null,
key: K.ExpressionKind,
kind: "constructor" | "method" | "get" | "set",
loc?: K.SourceLocationKind | null,
static?: boolean,
value: K.FunctionKind
}
): namedTypes.MethodDefinition;
}
export interface ClassPropertyDefinitionBuilder {
(
definition: K.MethodDefinitionKind | K.VariableDeclaratorKind | K.ClassPropertyDefinitionKind | K.ClassPropertyKind
): namedTypes.ClassPropertyDefinition;
from(
params: {
comments?: K.CommentKind[] | null,
definition: K.MethodDefinitionKind | K.VariableDeclaratorKind | K.ClassPropertyDefinitionKind | K.ClassPropertyKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.ClassPropertyDefinition;
}
export interface ClassPropertyBuilder {
(
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
value: K.ExpressionKind | null,
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null,
staticParam?: boolean
): namedTypes.ClassProperty;
from(
params: {
access?: "public" | "private" | "protected" | undefined,
comments?: K.CommentKind[] | null,
computed?: boolean,
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
loc?: K.SourceLocationKind | null,
static?: boolean,
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null,
value: K.ExpressionKind | null,
variance?: K.VarianceKind | "plus" | "minus" | null
}
): namedTypes.ClassProperty;
}
export interface ClassBodyBuilder {
(
body: (K.MethodDefinitionKind | K.VariableDeclaratorKind | K.ClassPropertyDefinitionKind | K.ClassPropertyKind | K.ClassPrivatePropertyKind | K.ClassMethodKind | K.ClassPrivateMethodKind | K.TSDeclareMethodKind | K.TSCallSignatureDeclarationKind | K.TSConstructSignatureDeclarationKind | K.TSIndexSignatureKind | K.TSMethodSignatureKind | K.TSPropertySignatureKind)[]
): namedTypes.ClassBody;
from(
params: {
body: (K.MethodDefinitionKind | K.VariableDeclaratorKind | K.ClassPropertyDefinitionKind | K.ClassPropertyKind | K.ClassPrivatePropertyKind | K.ClassMethodKind | K.ClassPrivateMethodKind | K.TSDeclareMethodKind | K.TSCallSignatureDeclarationKind | K.TSConstructSignatureDeclarationKind | K.TSIndexSignatureKind | K.TSMethodSignatureKind | K.TSPropertySignatureKind)[],
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ClassBody;
}
export interface ClassDeclarationBuilder {
(
id: K.IdentifierKind | null,
body: K.ClassBodyKind,
superClass?: K.ExpressionKind | null
): namedTypes.ClassDeclaration;
from(
params: {
body: K.ClassBodyKind,
comments?: K.CommentKind[] | null,
id: K.IdentifierKind | null,
implements?: K.ClassImplementsKind[] | K.TSExpressionWithTypeArgumentsKind[],
loc?: K.SourceLocationKind | null,
superClass?: K.ExpressionKind | null,
superTypeParameters?: K.TypeParameterInstantiationKind | K.TSTypeParameterInstantiationKind | null,
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null
}
): namedTypes.ClassDeclaration;
}
export interface ClassExpressionBuilder {
(
id: K.IdentifierKind | null | undefined,
body: K.ClassBodyKind,
superClass?: K.ExpressionKind | null
): namedTypes.ClassExpression;
from(
params: {
body: K.ClassBodyKind,
comments?: K.CommentKind[] | null,
id?: K.IdentifierKind | null,
implements?: K.ClassImplementsKind[] | K.TSExpressionWithTypeArgumentsKind[],
loc?: K.SourceLocationKind | null,
superClass?: K.ExpressionKind | null,
superTypeParameters?: K.TypeParameterInstantiationKind | K.TSTypeParameterInstantiationKind | null,
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null
}
): namedTypes.ClassExpression;
}
export interface SuperBuilder {
(): namedTypes.Super;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.Super;
}
export interface ImportSpecifierBuilder {
(imported: K.IdentifierKind, local?: K.IdentifierKind | null): namedTypes.ImportSpecifier;
from(
params: {
comments?: K.CommentKind[] | null,
id?: K.IdentifierKind | null,
imported: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
local?: K.IdentifierKind | null,
name?: K.IdentifierKind | null
}
): namedTypes.ImportSpecifier;
}
export interface ImportDefaultSpecifierBuilder {
(local?: K.IdentifierKind | null): namedTypes.ImportDefaultSpecifier;
from(
params: {
comments?: K.CommentKind[] | null,
id?: K.IdentifierKind | null,
loc?: K.SourceLocationKind | null,
local?: K.IdentifierKind | null,
name?: K.IdentifierKind | null
}
): namedTypes.ImportDefaultSpecifier;
}
export interface ImportNamespaceSpecifierBuilder {
(local?: K.IdentifierKind | null): namedTypes.ImportNamespaceSpecifier;
from(
params: {
comments?: K.CommentKind[] | null,
id?: K.IdentifierKind | null,
loc?: K.SourceLocationKind | null,
local?: K.IdentifierKind | null,
name?: K.IdentifierKind | null
}
): namedTypes.ImportNamespaceSpecifier;
}
export interface ImportDeclarationBuilder {
(
specifiers: (K.ImportSpecifierKind | K.ImportNamespaceSpecifierKind | K.ImportDefaultSpecifierKind)[] | undefined,
source: K.LiteralKind,
importKind?: "value" | "type" | "typeof"
): namedTypes.ImportDeclaration;
from(
params: {
assertions?: K.ImportAttributeKind[],
comments?: K.CommentKind[] | null,
importKind?: "value" | "type" | "typeof",
loc?: K.SourceLocationKind | null,
source: K.LiteralKind,
specifiers?: (K.ImportSpecifierKind | K.ImportNamespaceSpecifierKind | K.ImportDefaultSpecifierKind)[]
}
): namedTypes.ImportDeclaration;
}
export interface ExportNamedDeclarationBuilder {
(
declaration: K.DeclarationKind | null,
specifiers?: K.ExportSpecifierKind[],
source?: K.LiteralKind | null
): namedTypes.ExportNamedDeclaration;
from(
params: {
assertions?: K.ImportAttributeKind[],
comments?: K.CommentKind[] | null,
declaration: K.DeclarationKind | null,
loc?: K.SourceLocationKind | null,
source?: K.LiteralKind | null,
specifiers?: K.ExportSpecifierKind[]
}
): namedTypes.ExportNamedDeclaration;
}
export interface ExportSpecifierBuilder {
(id?: K.IdentifierKind | null, name?: K.IdentifierKind | null): namedTypes.ExportSpecifier;
from(
params: {
comments?: K.CommentKind[] | null,
exported: K.IdentifierKind,
id?: K.IdentifierKind | null,
loc?: K.SourceLocationKind | null,
local?: K.IdentifierKind | null,
name?: K.IdentifierKind | null
}
): namedTypes.ExportSpecifier;
}
export interface ExportDefaultDeclarationBuilder {
(declaration: K.DeclarationKind | K.ExpressionKind): namedTypes.ExportDefaultDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
declaration: K.DeclarationKind | K.ExpressionKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.ExportDefaultDeclaration;
}
export interface ExportAllDeclarationBuilder {
(source: K.LiteralKind, exported: K.IdentifierKind | null): namedTypes.ExportAllDeclaration;
from(
params: {
assertions?: K.ImportAttributeKind[],
comments?: K.CommentKind[] | null,
exported: K.IdentifierKind | null,
loc?: K.SourceLocationKind | null,
source: K.LiteralKind
}
): namedTypes.ExportAllDeclaration;
}
export interface TaggedTemplateExpressionBuilder {
(tag: K.ExpressionKind, quasi: K.TemplateLiteralKind): namedTypes.TaggedTemplateExpression;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
quasi: K.TemplateLiteralKind,
tag: K.ExpressionKind
}
): namedTypes.TaggedTemplateExpression;
}
export interface TemplateLiteralBuilder {
(
quasis: K.TemplateElementKind[],
expressions: K.ExpressionKind[] | K.TSTypeKind[]
): namedTypes.TemplateLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
expressions: K.ExpressionKind[] | K.TSTypeKind[],
loc?: K.SourceLocationKind | null,
quasis: K.TemplateElementKind[]
}
): namedTypes.TemplateLiteral;
}
export interface TemplateElementBuilder {
(
value: {
cooked: string | null,
raw: string
},
tail: boolean
): namedTypes.TemplateElement;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
tail: boolean,
value: {
cooked: string | null,
raw: string
}
}
): namedTypes.TemplateElement;
}
export interface MetaPropertyBuilder {
(meta: K.IdentifierKind, property: K.IdentifierKind): namedTypes.MetaProperty;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
meta: K.IdentifierKind,
property: K.IdentifierKind
}
): namedTypes.MetaProperty;
}
export interface AwaitExpressionBuilder {
(argument: K.ExpressionKind | null, all?: boolean): namedTypes.AwaitExpression;
from(
params: {
all?: boolean,
argument: K.ExpressionKind | null,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.AwaitExpression;
}
export interface SpreadPropertyBuilder {
(argument: K.ExpressionKind): namedTypes.SpreadProperty;
from(
params: {
argument: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.SpreadProperty;
}
export interface SpreadPropertyPatternBuilder {
(argument: K.PatternKind): namedTypes.SpreadPropertyPattern;
from(
params: {
argument: K.PatternKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.SpreadPropertyPattern;
}
export interface ImportExpressionBuilder {
(source: K.ExpressionKind): namedTypes.ImportExpression;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
source: K.ExpressionKind
}
): namedTypes.ImportExpression;
}
export interface ChainExpressionBuilder {
(expression: K.ChainElementKind): namedTypes.ChainExpression;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ChainElementKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.ChainExpression;
}
export interface OptionalCallExpressionBuilder {
(
callee: K.ExpressionKind,
argumentsParam: (K.ExpressionKind | K.SpreadElementKind)[],
optional?: boolean
): namedTypes.OptionalCallExpression;
from(
params: {
arguments: (K.ExpressionKind | K.SpreadElementKind)[],
callee: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
optional?: boolean,
typeArguments?: null | K.TypeParameterInstantiationKind
}
): namedTypes.OptionalCallExpression;
}
export interface OptionalMemberExpressionBuilder {
(
object: K.ExpressionKind,
property: K.IdentifierKind | K.ExpressionKind,
computed?: boolean,
optional?: boolean
): namedTypes.OptionalMemberExpression;
from(
params: {
comments?: K.CommentKind[] | null,
computed?: boolean,
loc?: K.SourceLocationKind | null,
object: K.ExpressionKind,
optional?: boolean,
property: K.IdentifierKind | K.ExpressionKind
}
): namedTypes.OptionalMemberExpression;
}
export interface StaticBlockBuilder {
(body: K.StatementKind[]): namedTypes.StaticBlock;
from(
params: {
body: K.StatementKind[],
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.StaticBlock;
}
export interface DecoratorBuilder {
(expression: K.ExpressionKind): namedTypes.Decorator;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.Decorator;
}
export interface PrivateNameBuilder {
(id: K.IdentifierKind): namedTypes.PrivateName;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.PrivateName;
}
export interface ClassPrivatePropertyBuilder {
(key: K.PrivateNameKind, value?: K.ExpressionKind | null): namedTypes.ClassPrivateProperty;
from(
params: {
access?: "public" | "private" | "protected" | undefined,
comments?: K.CommentKind[] | null,
computed?: boolean,
key: K.PrivateNameKind,
loc?: K.SourceLocationKind | null,
static?: boolean,
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null,
value?: K.ExpressionKind | null,
variance?: K.VarianceKind | "plus" | "minus" | null
}
): namedTypes.ClassPrivateProperty;
}
export interface ImportAttributeBuilder {
(key: K.IdentifierKind | K.LiteralKind, value: K.ExpressionKind): namedTypes.ImportAttribute;
from(
params: {
comments?: K.CommentKind[] | null,
key: K.IdentifierKind | K.LiteralKind,
loc?: K.SourceLocationKind | null,
value: K.ExpressionKind
}
): namedTypes.ImportAttribute;
}
export interface RecordExpressionBuilder {
(
properties: (K.ObjectPropertyKind | K.ObjectMethodKind | K.SpreadElementKind)[]
): namedTypes.RecordExpression;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
properties: (K.ObjectPropertyKind | K.ObjectMethodKind | K.SpreadElementKind)[]
}
): namedTypes.RecordExpression;
}
export interface ObjectMethodBuilder {
(
kind: "method" | "get" | "set",
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
params: K.PatternKind[],
body: K.BlockStatementKind,
computed?: boolean
): namedTypes.ObjectMethod;
from(
params: {
accessibility?: K.LiteralKind | null,
async?: boolean,
body: K.BlockStatementKind,
comments?: K.CommentKind[] | null,
computed?: boolean,
decorators?: K.DecoratorKind[] | null,
defaults?: (K.ExpressionKind | null)[],
expression?: boolean,
generator?: boolean,
id?: K.IdentifierKind | null,
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
kind: "method" | "get" | "set",
loc?: K.SourceLocationKind | null,
params: K.PatternKind[],
predicate?: K.FlowPredicateKind | null,
rest?: K.IdentifierKind | null,
returnType?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null,
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null
}
): namedTypes.ObjectMethod;
}
export interface TupleExpressionBuilder {
(elements: (K.ExpressionKind | K.SpreadElementKind | null)[]): namedTypes.TupleExpression;
from(
params: {
comments?: K.CommentKind[] | null,
elements: (K.ExpressionKind | K.SpreadElementKind | null)[],
loc?: K.SourceLocationKind | null
}
): namedTypes.TupleExpression;
}
export interface ModuleExpressionBuilder {
(body: K.ProgramKind): namedTypes.ModuleExpression;
from(
params: {
body: K.ProgramKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ModuleExpression;
}
export interface JSXAttributeBuilder {
(
name: K.JSXIdentifierKind | K.JSXNamespacedNameKind,
value?: K.LiteralKind | K.JSXExpressionContainerKind | K.JSXElementKind | K.JSXFragmentKind | null
): namedTypes.JSXAttribute;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name: K.JSXIdentifierKind | K.JSXNamespacedNameKind,
value?: K.LiteralKind | K.JSXExpressionContainerKind | K.JSXElementKind | K.JSXFragmentKind | null
}
): namedTypes.JSXAttribute;
}
export interface JSXIdentifierBuilder {
(name: string): namedTypes.JSXIdentifier;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name: string,
optional?: boolean,
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null
}
): namedTypes.JSXIdentifier;
}
export interface JSXNamespacedNameBuilder {
(namespace: K.JSXIdentifierKind, name: K.JSXIdentifierKind): namedTypes.JSXNamespacedName;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name: K.JSXIdentifierKind,
namespace: K.JSXIdentifierKind
}
): namedTypes.JSXNamespacedName;
}
export interface JSXExpressionContainerBuilder {
(expression: K.ExpressionKind | K.JSXEmptyExpressionKind): namedTypes.JSXExpressionContainer;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind | K.JSXEmptyExpressionKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.JSXExpressionContainer;
}
export interface JSXElementBuilder {
(
openingElement: K.JSXOpeningElementKind,
closingElement?: K.JSXClosingElementKind | null,
children?: (K.JSXTextKind | K.JSXExpressionContainerKind | K.JSXSpreadChildKind | K.JSXElementKind | K.JSXFragmentKind | K.LiteralKind)[]
): namedTypes.JSXElement;
from(
params: {
attributes?: (K.JSXAttributeKind | K.JSXSpreadAttributeKind)[],
children?: (K.JSXTextKind | K.JSXExpressionContainerKind | K.JSXSpreadChildKind | K.JSXElementKind | K.JSXFragmentKind | K.LiteralKind)[],
closingElement?: K.JSXClosingElementKind | null,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name?: K.JSXIdentifierKind | K.JSXNamespacedNameKind | K.JSXMemberExpressionKind,
openingElement: K.JSXOpeningElementKind,
selfClosing?: boolean
}
): namedTypes.JSXElement;
}
export interface JSXFragmentBuilder {
(
openingFragment: K.JSXOpeningFragmentKind,
closingFragment: K.JSXClosingFragmentKind,
children?: (K.JSXTextKind | K.JSXExpressionContainerKind | K.JSXSpreadChildKind | K.JSXElementKind | K.JSXFragmentKind | K.LiteralKind)[]
): namedTypes.JSXFragment;
from(
params: {
children?: (K.JSXTextKind | K.JSXExpressionContainerKind | K.JSXSpreadChildKind | K.JSXElementKind | K.JSXFragmentKind | K.LiteralKind)[],
closingFragment: K.JSXClosingFragmentKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
openingFragment: K.JSXOpeningFragmentKind
}
): namedTypes.JSXFragment;
}
export interface JSXMemberExpressionBuilder {
(
object: K.JSXIdentifierKind | K.JSXMemberExpressionKind,
property: K.JSXIdentifierKind
): namedTypes.JSXMemberExpression;
from(
params: {
comments?: K.CommentKind[] | null,
computed?: boolean,
loc?: K.SourceLocationKind | null,
object: K.JSXIdentifierKind | K.JSXMemberExpressionKind,
optional?: boolean,
property: K.JSXIdentifierKind
}
): namedTypes.JSXMemberExpression;
}
export interface JSXSpreadAttributeBuilder {
(argument: K.ExpressionKind): namedTypes.JSXSpreadAttribute;
from(
params: {
argument: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.JSXSpreadAttribute;
}
export interface JSXEmptyExpressionBuilder {
(): namedTypes.JSXEmptyExpression;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.JSXEmptyExpression;
}
export interface JSXTextBuilder {
(value: string, raw?: string): namedTypes.JSXText;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
raw?: string,
value: string
}
): namedTypes.JSXText;
}
export interface JSXSpreadChildBuilder {
(expression: K.ExpressionKind): namedTypes.JSXSpreadChild;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.JSXSpreadChild;
}
export interface JSXOpeningElementBuilder {
(
name: K.JSXIdentifierKind | K.JSXNamespacedNameKind | K.JSXMemberExpressionKind,
attributes?: (K.JSXAttributeKind | K.JSXSpreadAttributeKind)[],
selfClosing?: boolean
): namedTypes.JSXOpeningElement;
from(
params: {
attributes?: (K.JSXAttributeKind | K.JSXSpreadAttributeKind)[],
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name: K.JSXIdentifierKind | K.JSXNamespacedNameKind | K.JSXMemberExpressionKind,
selfClosing?: boolean
}
): namedTypes.JSXOpeningElement;
}
export interface JSXClosingElementBuilder {
(
name: K.JSXIdentifierKind | K.JSXNamespacedNameKind | K.JSXMemberExpressionKind
): namedTypes.JSXClosingElement;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name: K.JSXIdentifierKind | K.JSXNamespacedNameKind | K.JSXMemberExpressionKind
}
): namedTypes.JSXClosingElement;
}
export interface JSXOpeningFragmentBuilder {
(): namedTypes.JSXOpeningFragment;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.JSXOpeningFragment;
}
export interface JSXClosingFragmentBuilder {
(): namedTypes.JSXClosingFragment;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.JSXClosingFragment;
}
export interface TypeParameterDeclarationBuilder {
(params: K.TypeParameterKind[]): namedTypes.TypeParameterDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
params: K.TypeParameterKind[]
}
): namedTypes.TypeParameterDeclaration;
}
export interface TSTypeParameterDeclarationBuilder {
(params: K.TSTypeParameterKind[]): namedTypes.TSTypeParameterDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
params: K.TSTypeParameterKind[]
}
): namedTypes.TSTypeParameterDeclaration;
}
export interface TypeParameterInstantiationBuilder {
(params: K.FlowTypeKind[]): namedTypes.TypeParameterInstantiation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
params: K.FlowTypeKind[]
}
): namedTypes.TypeParameterInstantiation;
}
export interface TSTypeParameterInstantiationBuilder {
(params: K.TSTypeKind[]): namedTypes.TSTypeParameterInstantiation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
params: K.TSTypeKind[]
}
): namedTypes.TSTypeParameterInstantiation;
}
export interface ClassImplementsBuilder {
(id: K.IdentifierKind): namedTypes.ClassImplements;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
superClass?: K.ExpressionKind | null,
typeParameters?: K.TypeParameterInstantiationKind | null
}
): namedTypes.ClassImplements;
}
export interface TSExpressionWithTypeArgumentsBuilder {
(
expression: K.IdentifierKind | K.TSQualifiedNameKind,
typeParameters?: K.TSTypeParameterInstantiationKind | null
): namedTypes.TSExpressionWithTypeArguments;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.IdentifierKind | K.TSQualifiedNameKind,
loc?: K.SourceLocationKind | null,
typeParameters?: K.TSTypeParameterInstantiationKind | null
}
): namedTypes.TSExpressionWithTypeArguments;
}
export interface AnyTypeAnnotationBuilder {
(): namedTypes.AnyTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.AnyTypeAnnotation;
}
export interface EmptyTypeAnnotationBuilder {
(): namedTypes.EmptyTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.EmptyTypeAnnotation;
}
export interface MixedTypeAnnotationBuilder {
(): namedTypes.MixedTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.MixedTypeAnnotation;
}
export interface VoidTypeAnnotationBuilder {
(): namedTypes.VoidTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.VoidTypeAnnotation;
}
export interface SymbolTypeAnnotationBuilder {
(): namedTypes.SymbolTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.SymbolTypeAnnotation;
}
export interface NumberTypeAnnotationBuilder {
(): namedTypes.NumberTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.NumberTypeAnnotation;
}
export interface BigIntTypeAnnotationBuilder {
(): namedTypes.BigIntTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.BigIntTypeAnnotation;
}
export interface NumberLiteralTypeAnnotationBuilder {
(value: number, raw: string): namedTypes.NumberLiteralTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
raw: string,
value: number
}
): namedTypes.NumberLiteralTypeAnnotation;
}
export interface NumericLiteralTypeAnnotationBuilder {
(value: number, raw: string): namedTypes.NumericLiteralTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
raw: string,
value: number
}
): namedTypes.NumericLiteralTypeAnnotation;
}
export interface BigIntLiteralTypeAnnotationBuilder {
(value: null, raw: string): namedTypes.BigIntLiteralTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
raw: string,
value: null
}
): namedTypes.BigIntLiteralTypeAnnotation;
}
export interface StringTypeAnnotationBuilder {
(): namedTypes.StringTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.StringTypeAnnotation;
}
export interface StringLiteralTypeAnnotationBuilder {
(value: string, raw: string): namedTypes.StringLiteralTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
raw: string,
value: string
}
): namedTypes.StringLiteralTypeAnnotation;
}
export interface BooleanTypeAnnotationBuilder {
(): namedTypes.BooleanTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.BooleanTypeAnnotation;
}
export interface BooleanLiteralTypeAnnotationBuilder {
(value: boolean, raw: string): namedTypes.BooleanLiteralTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
raw: string,
value: boolean
}
): namedTypes.BooleanLiteralTypeAnnotation;
}
export interface NullableTypeAnnotationBuilder {
(typeAnnotation: K.FlowTypeKind): namedTypes.NullableTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.FlowTypeKind
}
): namedTypes.NullableTypeAnnotation;
}
export interface NullLiteralTypeAnnotationBuilder {
(): namedTypes.NullLiteralTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.NullLiteralTypeAnnotation;
}
export interface NullTypeAnnotationBuilder {
(): namedTypes.NullTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.NullTypeAnnotation;
}
export interface ThisTypeAnnotationBuilder {
(): namedTypes.ThisTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ThisTypeAnnotation;
}
export interface ExistsTypeAnnotationBuilder {
(): namedTypes.ExistsTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ExistsTypeAnnotation;
}
export interface ExistentialTypeParamBuilder {
(): namedTypes.ExistentialTypeParam;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ExistentialTypeParam;
}
export interface FunctionTypeAnnotationBuilder {
(
params: K.FunctionTypeParamKind[],
returnType: K.FlowTypeKind,
rest: K.FunctionTypeParamKind | null,
typeParameters: K.TypeParameterDeclarationKind | null
): namedTypes.FunctionTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
params: K.FunctionTypeParamKind[],
rest: K.FunctionTypeParamKind | null,
returnType: K.FlowTypeKind,
typeParameters: K.TypeParameterDeclarationKind | null
}
): namedTypes.FunctionTypeAnnotation;
}
export interface FunctionTypeParamBuilder {
(
name: K.IdentifierKind | null,
typeAnnotation: K.FlowTypeKind,
optional: boolean
): namedTypes.FunctionTypeParam;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name: K.IdentifierKind | null,
optional: boolean,
typeAnnotation: K.FlowTypeKind
}
): namedTypes.FunctionTypeParam;
}
export interface ArrayTypeAnnotationBuilder {
(elementType: K.FlowTypeKind): namedTypes.ArrayTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
elementType: K.FlowTypeKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.ArrayTypeAnnotation;
}
export interface ObjectTypeAnnotationBuilder {
(
properties: (K.ObjectTypePropertyKind | K.ObjectTypeSpreadPropertyKind)[],
indexers?: K.ObjectTypeIndexerKind[],
callProperties?: K.ObjectTypeCallPropertyKind[]
): namedTypes.ObjectTypeAnnotation;
from(
params: {
callProperties?: K.ObjectTypeCallPropertyKind[],
comments?: K.CommentKind[] | null,
exact?: boolean,
indexers?: K.ObjectTypeIndexerKind[],
inexact?: boolean | undefined,
internalSlots?: K.ObjectTypeInternalSlotKind[],
loc?: K.SourceLocationKind | null,
properties: (K.ObjectTypePropertyKind | K.ObjectTypeSpreadPropertyKind)[]
}
): namedTypes.ObjectTypeAnnotation;
}
export interface ObjectTypePropertyBuilder {
(
key: K.LiteralKind | K.IdentifierKind,
value: K.FlowTypeKind,
optional: boolean
): namedTypes.ObjectTypeProperty;
from(
params: {
comments?: K.CommentKind[] | null,
key: K.LiteralKind | K.IdentifierKind,
loc?: K.SourceLocationKind | null,
optional: boolean,
value: K.FlowTypeKind,
variance?: K.VarianceKind | "plus" | "minus" | null
}
): namedTypes.ObjectTypeProperty;
}
export interface ObjectTypeSpreadPropertyBuilder {
(argument: K.FlowTypeKind): namedTypes.ObjectTypeSpreadProperty;
from(
params: {
argument: K.FlowTypeKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ObjectTypeSpreadProperty;
}
export interface ObjectTypeIndexerBuilder {
(id: K.IdentifierKind, key: K.FlowTypeKind, value: K.FlowTypeKind): namedTypes.ObjectTypeIndexer;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
key: K.FlowTypeKind,
loc?: K.SourceLocationKind | null,
static?: boolean,
value: K.FlowTypeKind,
variance?: K.VarianceKind | "plus" | "minus" | null
}
): namedTypes.ObjectTypeIndexer;
}
export interface ObjectTypeCallPropertyBuilder {
(value: K.FunctionTypeAnnotationKind): namedTypes.ObjectTypeCallProperty;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
static?: boolean,
value: K.FunctionTypeAnnotationKind
}
): namedTypes.ObjectTypeCallProperty;
}
export interface ObjectTypeInternalSlotBuilder {
(
id: K.IdentifierKind,
value: K.FlowTypeKind,
optional: boolean,
staticParam: boolean,
method: boolean
): namedTypes.ObjectTypeInternalSlot;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
method: boolean,
optional: boolean,
static: boolean,
value: K.FlowTypeKind
}
): namedTypes.ObjectTypeInternalSlot;
}
export interface VarianceBuilder {
(kind: "plus" | "minus"): namedTypes.Variance;
from(
params: {
comments?: K.CommentKind[] | null,
kind: "plus" | "minus",
loc?: K.SourceLocationKind | null
}
): namedTypes.Variance;
}
export interface QualifiedTypeIdentifierBuilder {
(
qualification: K.IdentifierKind | K.QualifiedTypeIdentifierKind,
id: K.IdentifierKind
): namedTypes.QualifiedTypeIdentifier;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
qualification: K.IdentifierKind | K.QualifiedTypeIdentifierKind
}
): namedTypes.QualifiedTypeIdentifier;
}
export interface GenericTypeAnnotationBuilder {
(
id: K.IdentifierKind | K.QualifiedTypeIdentifierKind,
typeParameters: K.TypeParameterInstantiationKind | null
): namedTypes.GenericTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind | K.QualifiedTypeIdentifierKind,
loc?: K.SourceLocationKind | null,
typeParameters: K.TypeParameterInstantiationKind | null
}
): namedTypes.GenericTypeAnnotation;
}
export interface MemberTypeAnnotationBuilder {
(
object: K.IdentifierKind,
property: K.MemberTypeAnnotationKind | K.GenericTypeAnnotationKind
): namedTypes.MemberTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
object: K.IdentifierKind,
property: K.MemberTypeAnnotationKind | K.GenericTypeAnnotationKind
}
): namedTypes.MemberTypeAnnotation;
}
export interface IndexedAccessTypeBuilder {
(objectType: K.FlowTypeKind, indexType: K.FlowTypeKind): namedTypes.IndexedAccessType;
from(
params: {
comments?: K.CommentKind[] | null,
indexType: K.FlowTypeKind,
loc?: K.SourceLocationKind | null,
objectType: K.FlowTypeKind
}
): namedTypes.IndexedAccessType;
}
export interface OptionalIndexedAccessTypeBuilder {
(objectType: K.FlowTypeKind, indexType: K.FlowTypeKind, optional: boolean): namedTypes.OptionalIndexedAccessType;
from(
params: {
comments?: K.CommentKind[] | null,
indexType: K.FlowTypeKind,
loc?: K.SourceLocationKind | null,
objectType: K.FlowTypeKind,
optional: boolean
}
): namedTypes.OptionalIndexedAccessType;
}
export interface UnionTypeAnnotationBuilder {
(types: K.FlowTypeKind[]): namedTypes.UnionTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
types: K.FlowTypeKind[]
}
): namedTypes.UnionTypeAnnotation;
}
export interface IntersectionTypeAnnotationBuilder {
(types: K.FlowTypeKind[]): namedTypes.IntersectionTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
types: K.FlowTypeKind[]
}
): namedTypes.IntersectionTypeAnnotation;
}
export interface TypeofTypeAnnotationBuilder {
(argument: K.FlowTypeKind): namedTypes.TypeofTypeAnnotation;
from(
params: {
argument: K.FlowTypeKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TypeofTypeAnnotation;
}
export interface TypeParameterBuilder {
(
name: string,
variance?: K.VarianceKind | "plus" | "minus" | null,
bound?: K.TypeAnnotationKind | null,
defaultParam?: K.FlowTypeKind | null
): namedTypes.TypeParameter;
from(
params: {
bound?: K.TypeAnnotationKind | null,
comments?: K.CommentKind[] | null,
default?: K.FlowTypeKind | null,
loc?: K.SourceLocationKind | null,
name: string,
variance?: K.VarianceKind | "plus" | "minus" | null
}
): namedTypes.TypeParameter;
}
export interface InterfaceTypeAnnotationBuilder {
(
body: K.ObjectTypeAnnotationKind,
extendsParam?: K.InterfaceExtendsKind[] | null
): namedTypes.InterfaceTypeAnnotation;
from(
params: {
body: K.ObjectTypeAnnotationKind,
comments?: K.CommentKind[] | null,
extends?: K.InterfaceExtendsKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.InterfaceTypeAnnotation;
}
export interface InterfaceExtendsBuilder {
(id: K.IdentifierKind): namedTypes.InterfaceExtends;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
typeParameters?: K.TypeParameterInstantiationKind | null
}
): namedTypes.InterfaceExtends;
}
export interface InterfaceDeclarationBuilder {
(
id: K.IdentifierKind,
body: K.ObjectTypeAnnotationKind,
extendsParam: K.InterfaceExtendsKind[]
): namedTypes.InterfaceDeclaration;
from(
params: {
body: K.ObjectTypeAnnotationKind,
comments?: K.CommentKind[] | null,
extends: K.InterfaceExtendsKind[],
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
typeParameters?: K.TypeParameterDeclarationKind | null
}
): namedTypes.InterfaceDeclaration;
}
export interface DeclareInterfaceBuilder {
(
id: K.IdentifierKind,
body: K.ObjectTypeAnnotationKind,
extendsParam: K.InterfaceExtendsKind[]
): namedTypes.DeclareInterface;
from(
params: {
body: K.ObjectTypeAnnotationKind,
comments?: K.CommentKind[] | null,
extends: K.InterfaceExtendsKind[],
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
typeParameters?: K.TypeParameterDeclarationKind | null
}
): namedTypes.DeclareInterface;
}
export interface TypeAliasBuilder {
(
id: K.IdentifierKind,
typeParameters: K.TypeParameterDeclarationKind | null,
right: K.FlowTypeKind
): namedTypes.TypeAlias;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
right: K.FlowTypeKind,
typeParameters: K.TypeParameterDeclarationKind | null
}
): namedTypes.TypeAlias;
}
export interface DeclareTypeAliasBuilder {
(
id: K.IdentifierKind,
typeParameters: K.TypeParameterDeclarationKind | null,
right: K.FlowTypeKind
): namedTypes.DeclareTypeAlias;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
right: K.FlowTypeKind,
typeParameters: K.TypeParameterDeclarationKind | null
}
): namedTypes.DeclareTypeAlias;
}
export interface OpaqueTypeBuilder {
(
id: K.IdentifierKind,
typeParameters: K.TypeParameterDeclarationKind | null,
impltype: K.FlowTypeKind,
supertype: K.FlowTypeKind | null
): namedTypes.OpaqueType;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
impltype: K.FlowTypeKind,
loc?: K.SourceLocationKind | null,
supertype: K.FlowTypeKind | null,
typeParameters: K.TypeParameterDeclarationKind | null
}
): namedTypes.OpaqueType;
}
export interface DeclareOpaqueTypeBuilder {
(
id: K.IdentifierKind,
typeParameters: K.TypeParameterDeclarationKind | null,
supertype: K.FlowTypeKind | null
): namedTypes.DeclareOpaqueType;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
impltype: K.FlowTypeKind | null,
loc?: K.SourceLocationKind | null,
supertype: K.FlowTypeKind | null,
typeParameters: K.TypeParameterDeclarationKind | null
}
): namedTypes.DeclareOpaqueType;
}
export interface TypeCastExpressionBuilder {
(expression: K.ExpressionKind, typeAnnotation: K.TypeAnnotationKind): namedTypes.TypeCastExpression;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.TypeAnnotationKind
}
): namedTypes.TypeCastExpression;
}
export interface TupleTypeAnnotationBuilder {
(types: K.FlowTypeKind[]): namedTypes.TupleTypeAnnotation;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
types: K.FlowTypeKind[]
}
): namedTypes.TupleTypeAnnotation;
}
export interface DeclareVariableBuilder {
(id: K.IdentifierKind): namedTypes.DeclareVariable;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.DeclareVariable;
}
export interface DeclareFunctionBuilder {
(id: K.IdentifierKind): namedTypes.DeclareFunction;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
predicate?: K.FlowPredicateKind | null
}
): namedTypes.DeclareFunction;
}
export interface DeclareClassBuilder {
(id: K.IdentifierKind): namedTypes.DeclareClass;
from(
params: {
body: K.ObjectTypeAnnotationKind,
comments?: K.CommentKind[] | null,
extends: K.InterfaceExtendsKind[],
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
typeParameters?: K.TypeParameterDeclarationKind | null
}
): namedTypes.DeclareClass;
}
export interface DeclareModuleBuilder {
(id: K.IdentifierKind | K.LiteralKind, body: K.BlockStatementKind): namedTypes.DeclareModule;
from(
params: {
body: K.BlockStatementKind,
comments?: K.CommentKind[] | null,
id: K.IdentifierKind | K.LiteralKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.DeclareModule;
}
export interface DeclareModuleExportsBuilder {
(typeAnnotation: K.TypeAnnotationKind): namedTypes.DeclareModuleExports;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.TypeAnnotationKind
}
): namedTypes.DeclareModuleExports;
}
export interface DeclareExportDeclarationBuilder {
(
defaultParam: boolean,
declaration: K.DeclareVariableKind | K.DeclareFunctionKind | K.DeclareClassKind | K.FlowTypeKind | K.TypeAliasKind | K.DeclareOpaqueTypeKind | K.InterfaceDeclarationKind | null,
specifiers?: (K.ExportSpecifierKind | K.ExportBatchSpecifierKind)[],
source?: K.LiteralKind | null
): namedTypes.DeclareExportDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
declaration: K.DeclareVariableKind | K.DeclareFunctionKind | K.DeclareClassKind | K.FlowTypeKind | K.TypeAliasKind | K.DeclareOpaqueTypeKind | K.InterfaceDeclarationKind | null,
default: boolean,
loc?: K.SourceLocationKind | null,
source?: K.LiteralKind | null,
specifiers?: (K.ExportSpecifierKind | K.ExportBatchSpecifierKind)[]
}
): namedTypes.DeclareExportDeclaration;
}
export interface ExportBatchSpecifierBuilder {
(): namedTypes.ExportBatchSpecifier;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.ExportBatchSpecifier;
}
export interface DeclareExportAllDeclarationBuilder {
(source?: K.LiteralKind | null): namedTypes.DeclareExportAllDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
source?: K.LiteralKind | null
}
): namedTypes.DeclareExportAllDeclaration;
}
export interface InferredPredicateBuilder {
(): namedTypes.InferredPredicate;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.InferredPredicate;
}
export interface DeclaredPredicateBuilder {
(value: K.ExpressionKind): namedTypes.DeclaredPredicate;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
value: K.ExpressionKind
}
): namedTypes.DeclaredPredicate;
}
export interface EnumDeclarationBuilder {
(
id: K.IdentifierKind,
body: K.EnumBooleanBodyKind | K.EnumNumberBodyKind | K.EnumStringBodyKind | K.EnumSymbolBodyKind
): namedTypes.EnumDeclaration;
from(
params: {
body: K.EnumBooleanBodyKind | K.EnumNumberBodyKind | K.EnumStringBodyKind | K.EnumSymbolBodyKind,
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.EnumDeclaration;
}
export interface EnumBooleanBodyBuilder {
(members: K.EnumBooleanMemberKind[], explicitType: boolean): namedTypes.EnumBooleanBody;
from(
params: {
explicitType: boolean,
members: K.EnumBooleanMemberKind[]
}
): namedTypes.EnumBooleanBody;
}
export interface EnumNumberBodyBuilder {
(members: K.EnumNumberMemberKind[], explicitType: boolean): namedTypes.EnumNumberBody;
from(
params: {
explicitType: boolean,
members: K.EnumNumberMemberKind[]
}
): namedTypes.EnumNumberBody;
}
export interface EnumStringBodyBuilder {
(
members: K.EnumStringMemberKind[] | K.EnumDefaultedMemberKind[],
explicitType: boolean
): namedTypes.EnumStringBody;
from(
params: {
explicitType: boolean,
members: K.EnumStringMemberKind[] | K.EnumDefaultedMemberKind[]
}
): namedTypes.EnumStringBody;
}
export interface EnumSymbolBodyBuilder {
(members: K.EnumDefaultedMemberKind[]): namedTypes.EnumSymbolBody;
from(
params: {
members: K.EnumDefaultedMemberKind[]
}
): namedTypes.EnumSymbolBody;
}
export interface EnumBooleanMemberBuilder {
(id: K.IdentifierKind, init: K.LiteralKind | boolean): namedTypes.EnumBooleanMember;
from(
params: {
id: K.IdentifierKind,
init: K.LiteralKind | boolean
}
): namedTypes.EnumBooleanMember;
}
export interface EnumNumberMemberBuilder {
(id: K.IdentifierKind, init: K.LiteralKind): namedTypes.EnumNumberMember;
from(
params: {
id: K.IdentifierKind,
init: K.LiteralKind
}
): namedTypes.EnumNumberMember;
}
export interface EnumStringMemberBuilder {
(id: K.IdentifierKind, init: K.LiteralKind): namedTypes.EnumStringMember;
from(
params: {
id: K.IdentifierKind,
init: K.LiteralKind
}
): namedTypes.EnumStringMember;
}
export interface EnumDefaultedMemberBuilder {
(id: K.IdentifierKind): namedTypes.EnumDefaultedMember;
from(
params: {
id: K.IdentifierKind
}
): namedTypes.EnumDefaultedMember;
}
export interface ExportDeclarationBuilder {
(
defaultParam: boolean,
declaration: K.DeclarationKind | K.ExpressionKind | null,
specifiers?: (K.ExportSpecifierKind | K.ExportBatchSpecifierKind)[],
source?: K.LiteralKind | null
): namedTypes.ExportDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
declaration: K.DeclarationKind | K.ExpressionKind | null,
default: boolean,
loc?: K.SourceLocationKind | null,
source?: K.LiteralKind | null,
specifiers?: (K.ExportSpecifierKind | K.ExportBatchSpecifierKind)[]
}
): namedTypes.ExportDeclaration;
}
export interface BlockBuilder {
(value: string, leading?: boolean, trailing?: boolean): namedTypes.Block;
from(
params: {
leading?: boolean,
loc?: K.SourceLocationKind | null,
trailing?: boolean,
value: string
}
): namedTypes.Block;
}
export interface LineBuilder {
(value: string, leading?: boolean, trailing?: boolean): namedTypes.Line;
from(
params: {
leading?: boolean,
loc?: K.SourceLocationKind | null,
trailing?: boolean,
value: string
}
): namedTypes.Line;
}
export interface NoopBuilder {
(): namedTypes.Noop;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.Noop;
}
export interface DoExpressionBuilder {
(body: K.StatementKind[]): namedTypes.DoExpression;
from(
params: {
body: K.StatementKind[],
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.DoExpression;
}
export interface BindExpressionBuilder {
(object: K.ExpressionKind | null, callee: K.ExpressionKind): namedTypes.BindExpression;
from(
params: {
callee: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
object: K.ExpressionKind | null
}
): namedTypes.BindExpression;
}
export interface ParenthesizedExpressionBuilder {
(expression: K.ExpressionKind): namedTypes.ParenthesizedExpression;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.ParenthesizedExpression;
}
export interface ExportNamespaceSpecifierBuilder {
(exported: K.IdentifierKind): namedTypes.ExportNamespaceSpecifier;
from(
params: {
comments?: K.CommentKind[] | null,
exported: K.IdentifierKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.ExportNamespaceSpecifier;
}
export interface ExportDefaultSpecifierBuilder {
(exported: K.IdentifierKind): namedTypes.ExportDefaultSpecifier;
from(
params: {
comments?: K.CommentKind[] | null,
exported: K.IdentifierKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.ExportDefaultSpecifier;
}
export interface CommentBlockBuilder {
(value: string, leading?: boolean, trailing?: boolean): namedTypes.CommentBlock;
from(
params: {
leading?: boolean,
loc?: K.SourceLocationKind | null,
trailing?: boolean,
value: string
}
): namedTypes.CommentBlock;
}
export interface CommentLineBuilder {
(value: string, leading?: boolean, trailing?: boolean): namedTypes.CommentLine;
from(
params: {
leading?: boolean,
loc?: K.SourceLocationKind | null,
trailing?: boolean,
value: string
}
): namedTypes.CommentLine;
}
export interface DirectiveBuilder {
(value: K.DirectiveLiteralKind): namedTypes.Directive;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
value: K.DirectiveLiteralKind
}
): namedTypes.Directive;
}
export interface DirectiveLiteralBuilder {
(value?: string): namedTypes.DirectiveLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
value?: string
}
): namedTypes.DirectiveLiteral;
}
export interface InterpreterDirectiveBuilder {
(value: string): namedTypes.InterpreterDirective;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
value: string
}
): namedTypes.InterpreterDirective;
}
export interface StringLiteralBuilder {
(value: string): namedTypes.StringLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
extra?: {
rawValue: string,
raw: string
},
loc?: K.SourceLocationKind | null,
value: string
}
): namedTypes.StringLiteral;
}
export interface NumericLiteralBuilder {
(value: number): namedTypes.NumericLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
extra?: {
rawValue: number,
raw: string
},
loc?: K.SourceLocationKind | null,
raw?: string | null,
value: number
}
): namedTypes.NumericLiteral;
}
export interface BigIntLiteralBuilder {
(value: string | number): namedTypes.BigIntLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
extra?: {
rawValue: string,
raw: string
},
loc?: K.SourceLocationKind | null,
value: string | number
}
): namedTypes.BigIntLiteral;
}
export interface DecimalLiteralBuilder {
(value: string): namedTypes.DecimalLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
extra?: {
rawValue: string,
raw: string
},
loc?: K.SourceLocationKind | null,
value: string
}
): namedTypes.DecimalLiteral;
}
export interface NullLiteralBuilder {
(): namedTypes.NullLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
value?: null
}
): namedTypes.NullLiteral;
}
export interface BooleanLiteralBuilder {
(value: boolean): namedTypes.BooleanLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
value: boolean
}
): namedTypes.BooleanLiteral;
}
export interface RegExpLiteralBuilder {
(pattern: string, flags: string): namedTypes.RegExpLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
extra?: {
rawValue: RegExp | undefined,
raw: string
},
flags: string,
loc?: K.SourceLocationKind | null,
pattern: string,
regex?: {
pattern: string,
flags: string
},
value?: RegExp
}
): namedTypes.RegExpLiteral;
}
export interface ClassMethodBuilder {
(
kind: "get" | "set" | "method" | "constructor" | undefined,
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
params: K.PatternKind[],
body: K.BlockStatementKind,
computed?: boolean,
staticParam?: boolean | null
): namedTypes.ClassMethod;
from(
params: {
abstract?: boolean | null,
access?: "public" | "private" | "protected" | null,
accessibility?: "public" | "private" | "protected" | null,
async?: boolean,
body: K.BlockStatementKind,
comments?: K.CommentKind[] | null,
computed?: boolean,
decorators?: K.DecoratorKind[] | null,
defaults?: (K.ExpressionKind | null)[],
expression?: boolean,
generator?: boolean,
id?: K.IdentifierKind | null,
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind,
kind?: "get" | "set" | "method" | "constructor",
loc?: K.SourceLocationKind | null,
optional?: boolean | null,
params: K.PatternKind[],
predicate?: K.FlowPredicateKind | null,
rest?: K.IdentifierKind | null,
returnType?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null,
static?: boolean | null,
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null
}
): namedTypes.ClassMethod;
}
export interface ClassPrivateMethodBuilder {
(
key: K.PrivateNameKind,
params: K.PatternKind[],
body: K.BlockStatementKind,
kind?: "get" | "set" | "method" | "constructor",
computed?: boolean,
staticParam?: boolean | null
): namedTypes.ClassPrivateMethod;
from(
params: {
abstract?: boolean | null,
access?: "public" | "private" | "protected" | null,
accessibility?: "public" | "private" | "protected" | null,
async?: boolean,
body: K.BlockStatementKind,
comments?: K.CommentKind[] | null,
computed?: boolean,
decorators?: K.DecoratorKind[] | null,
defaults?: (K.ExpressionKind | null)[],
expression?: boolean,
generator?: boolean,
id?: K.IdentifierKind | null,
key: K.PrivateNameKind,
kind?: "get" | "set" | "method" | "constructor",
loc?: K.SourceLocationKind | null,
optional?: boolean | null,
params: K.PatternKind[],
predicate?: K.FlowPredicateKind | null,
rest?: K.IdentifierKind | null,
returnType?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null,
static?: boolean | null,
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null
}
): namedTypes.ClassPrivateMethod;
}
export interface RestPropertyBuilder {
(argument: K.ExpressionKind): namedTypes.RestProperty;
from(
params: {
argument: K.ExpressionKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.RestProperty;
}
export interface ForAwaitStatementBuilder {
(
left: K.VariableDeclarationKind | K.ExpressionKind,
right: K.ExpressionKind,
body: K.StatementKind
): namedTypes.ForAwaitStatement;
from(
params: {
body: K.StatementKind,
comments?: K.CommentKind[] | null,
left: K.VariableDeclarationKind | K.ExpressionKind,
loc?: K.SourceLocationKind | null,
right: K.ExpressionKind
}
): namedTypes.ForAwaitStatement;
}
export interface ImportBuilder {
(): namedTypes.Import;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.Import;
}
export interface V8IntrinsicIdentifierBuilder {
(name: string): namedTypes.V8IntrinsicIdentifier;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
name: string
}
): namedTypes.V8IntrinsicIdentifier;
}
export interface TopicReferenceBuilder {
(): namedTypes.TopicReference;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TopicReference;
}
export interface TSQualifiedNameBuilder {
(
left: K.IdentifierKind | K.TSQualifiedNameKind,
right: K.IdentifierKind | K.TSQualifiedNameKind
): namedTypes.TSQualifiedName;
from(
params: {
comments?: K.CommentKind[] | null,
left: K.IdentifierKind | K.TSQualifiedNameKind,
loc?: K.SourceLocationKind | null,
right: K.IdentifierKind | K.TSQualifiedNameKind
}
): namedTypes.TSQualifiedName;
}
export interface TSTypeReferenceBuilder {
(
typeName: K.IdentifierKind | K.TSQualifiedNameKind,
typeParameters?: K.TSTypeParameterInstantiationKind | null
): namedTypes.TSTypeReference;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeName: K.IdentifierKind | K.TSQualifiedNameKind,
typeParameters?: K.TSTypeParameterInstantiationKind | null
}
): namedTypes.TSTypeReference;
}
export interface TSAsExpressionBuilder {
(expression: K.ExpressionKind, typeAnnotation: K.TSTypeKind): namedTypes.TSAsExpression;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind,
extra?: {
parenthesized: boolean
} | null,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.TSTypeKind
}
): namedTypes.TSAsExpression;
}
export interface TSNonNullExpressionBuilder {
(expression: K.ExpressionKind): namedTypes.TSNonNullExpression;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSNonNullExpression;
}
export interface TSAnyKeywordBuilder {
(): namedTypes.TSAnyKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSAnyKeyword;
}
export interface TSBigIntKeywordBuilder {
(): namedTypes.TSBigIntKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSBigIntKeyword;
}
export interface TSBooleanKeywordBuilder {
(): namedTypes.TSBooleanKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSBooleanKeyword;
}
export interface TSNeverKeywordBuilder {
(): namedTypes.TSNeverKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSNeverKeyword;
}
export interface TSNullKeywordBuilder {
(): namedTypes.TSNullKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSNullKeyword;
}
export interface TSNumberKeywordBuilder {
(): namedTypes.TSNumberKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSNumberKeyword;
}
export interface TSObjectKeywordBuilder {
(): namedTypes.TSObjectKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSObjectKeyword;
}
export interface TSStringKeywordBuilder {
(): namedTypes.TSStringKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSStringKeyword;
}
export interface TSSymbolKeywordBuilder {
(): namedTypes.TSSymbolKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSSymbolKeyword;
}
export interface TSUndefinedKeywordBuilder {
(): namedTypes.TSUndefinedKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSUndefinedKeyword;
}
export interface TSUnknownKeywordBuilder {
(): namedTypes.TSUnknownKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSUnknownKeyword;
}
export interface TSVoidKeywordBuilder {
(): namedTypes.TSVoidKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSVoidKeyword;
}
export interface TSIntrinsicKeywordBuilder {
(): namedTypes.TSIntrinsicKeyword;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSIntrinsicKeyword;
}
export interface TSThisTypeBuilder {
(): namedTypes.TSThisType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSThisType;
}
export interface TSArrayTypeBuilder {
(elementType: K.TSTypeKind): namedTypes.TSArrayType;
from(
params: {
comments?: K.CommentKind[] | null,
elementType: K.TSTypeKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSArrayType;
}
export interface TSLiteralTypeBuilder {
(
literal: K.NumericLiteralKind | K.StringLiteralKind | K.BooleanLiteralKind | K.TemplateLiteralKind | K.UnaryExpressionKind
): namedTypes.TSLiteralType;
from(
params: {
comments?: K.CommentKind[] | null,
literal: K.NumericLiteralKind | K.StringLiteralKind | K.BooleanLiteralKind | K.TemplateLiteralKind | K.UnaryExpressionKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSLiteralType;
}
export interface TSUnionTypeBuilder {
(types: K.TSTypeKind[]): namedTypes.TSUnionType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
types: K.TSTypeKind[]
}
): namedTypes.TSUnionType;
}
export interface TSIntersectionTypeBuilder {
(types: K.TSTypeKind[]): namedTypes.TSIntersectionType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
types: K.TSTypeKind[]
}
): namedTypes.TSIntersectionType;
}
export interface TSConditionalTypeBuilder {
(
checkType: K.TSTypeKind,
extendsType: K.TSTypeKind,
trueType: K.TSTypeKind,
falseType: K.TSTypeKind
): namedTypes.TSConditionalType;
from(
params: {
checkType: K.TSTypeKind,
comments?: K.CommentKind[] | null,
extendsType: K.TSTypeKind,
falseType: K.TSTypeKind,
loc?: K.SourceLocationKind | null,
trueType: K.TSTypeKind
}
): namedTypes.TSConditionalType;
}
export interface TSInferTypeBuilder {
(typeParameter: K.TSTypeParameterKind): namedTypes.TSInferType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeParameter: K.TSTypeParameterKind
}
): namedTypes.TSInferType;
}
export interface TSTypeParameterBuilder {
(
name: string,
constraint?: K.TSTypeKind | undefined,
defaultParam?: K.TSTypeKind | undefined
): namedTypes.TSTypeParameter;
from(
params: {
comments?: K.CommentKind[] | null,
constraint?: K.TSTypeKind | undefined,
default?: K.TSTypeKind | undefined,
loc?: K.SourceLocationKind | null,
name: string,
optional?: boolean,
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null
}
): namedTypes.TSTypeParameter;
}
export interface TSParenthesizedTypeBuilder {
(typeAnnotation: K.TSTypeKind): namedTypes.TSParenthesizedType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.TSTypeKind
}
): namedTypes.TSParenthesizedType;
}
export interface TSFunctionTypeBuilder {
(
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[]
): namedTypes.TSFunctionType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[],
typeAnnotation?: K.TSTypeAnnotationKind | null,
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined
}
): namedTypes.TSFunctionType;
}
export interface TSConstructorTypeBuilder {
(
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[]
): namedTypes.TSConstructorType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[],
typeAnnotation?: K.TSTypeAnnotationKind | null,
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined
}
): namedTypes.TSConstructorType;
}
export interface TSDeclareFunctionBuilder {
(
id: K.IdentifierKind | null | undefined,
params: K.PatternKind[],
returnType?: K.TSTypeAnnotationKind | K.NoopKind | null
): namedTypes.TSDeclareFunction;
from(
params: {
async?: boolean,
comments?: K.CommentKind[] | null,
declare?: boolean,
generator?: boolean,
id?: K.IdentifierKind | null,
loc?: K.SourceLocationKind | null,
params: K.PatternKind[],
returnType?: K.TSTypeAnnotationKind | K.NoopKind | null,
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined
}
): namedTypes.TSDeclareFunction;
}
export interface TSDeclareMethodBuilder {
(
key: K.IdentifierKind | K.StringLiteralKind | K.NumericLiteralKind | K.ExpressionKind,
params: K.PatternKind[],
returnType?: K.TSTypeAnnotationKind | K.NoopKind | null
): namedTypes.TSDeclareMethod;
from(
params: {
abstract?: boolean,
access?: "public" | "private" | "protected" | undefined,
accessibility?: "public" | "private" | "protected" | undefined,
async?: boolean,
comments?: K.CommentKind[] | null,
computed?: boolean,
decorators?: K.DecoratorKind[] | null,
generator?: boolean,
key: K.IdentifierKind | K.StringLiteralKind | K.NumericLiteralKind | K.ExpressionKind,
kind?: "get" | "set" | "method" | "constructor",
loc?: K.SourceLocationKind | null,
optional?: boolean,
params: K.PatternKind[],
returnType?: K.TSTypeAnnotationKind | K.NoopKind | null,
static?: boolean,
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined
}
): namedTypes.TSDeclareMethod;
}
export interface TSMappedTypeBuilder {
(typeParameter: K.TSTypeParameterKind, typeAnnotation?: K.TSTypeKind | null): namedTypes.TSMappedType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
optional?: boolean | "+" | "-",
readonly?: boolean | "+" | "-",
typeAnnotation?: K.TSTypeKind | null,
typeParameter: K.TSTypeParameterKind
}
): namedTypes.TSMappedType;
}
export interface TSTupleTypeBuilder {
(elementTypes: (K.TSTypeKind | K.TSNamedTupleMemberKind)[]): namedTypes.TSTupleType;
from(
params: {
comments?: K.CommentKind[] | null,
elementTypes: (K.TSTypeKind | K.TSNamedTupleMemberKind)[],
loc?: K.SourceLocationKind | null
}
): namedTypes.TSTupleType;
}
export interface TSNamedTupleMemberBuilder {
(label: K.IdentifierKind, elementType: K.TSTypeKind, optional?: boolean): namedTypes.TSNamedTupleMember;
from(
params: {
comments?: K.CommentKind[] | null,
elementType: K.TSTypeKind,
label: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
optional?: boolean
}
): namedTypes.TSNamedTupleMember;
}
export interface TSRestTypeBuilder {
(typeAnnotation: K.TSTypeKind): namedTypes.TSRestType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.TSTypeKind
}
): namedTypes.TSRestType;
}
export interface TSOptionalTypeBuilder {
(typeAnnotation: K.TSTypeKind): namedTypes.TSOptionalType;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.TSTypeKind
}
): namedTypes.TSOptionalType;
}
export interface TSIndexedAccessTypeBuilder {
(objectType: K.TSTypeKind, indexType: K.TSTypeKind): namedTypes.TSIndexedAccessType;
from(
params: {
comments?: K.CommentKind[] | null,
indexType: K.TSTypeKind,
loc?: K.SourceLocationKind | null,
objectType: K.TSTypeKind
}
): namedTypes.TSIndexedAccessType;
}
export interface TSTypeOperatorBuilder {
(operator: string): namedTypes.TSTypeOperator;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
operator: string,
typeAnnotation: K.TSTypeKind
}
): namedTypes.TSTypeOperator;
}
export interface TSIndexSignatureBuilder {
(
parameters: K.IdentifierKind[],
typeAnnotation?: K.TSTypeAnnotationKind | null
): namedTypes.TSIndexSignature;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
parameters: K.IdentifierKind[],
readonly?: boolean,
typeAnnotation?: K.TSTypeAnnotationKind | null
}
): namedTypes.TSIndexSignature;
}
export interface TSPropertySignatureBuilder {
(
key: K.ExpressionKind,
typeAnnotation?: K.TSTypeAnnotationKind | null,
optional?: boolean
): namedTypes.TSPropertySignature;
from(
params: {
comments?: K.CommentKind[] | null,
computed?: boolean,
initializer?: K.ExpressionKind | null,
key: K.ExpressionKind,
loc?: K.SourceLocationKind | null,
optional?: boolean,
readonly?: boolean,
typeAnnotation?: K.TSTypeAnnotationKind | null
}
): namedTypes.TSPropertySignature;
}
export interface TSMethodSignatureBuilder {
(
key: K.ExpressionKind,
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[],
typeAnnotation?: K.TSTypeAnnotationKind | null
): namedTypes.TSMethodSignature;
from(
params: {
comments?: K.CommentKind[] | null,
computed?: boolean,
key: K.ExpressionKind,
loc?: K.SourceLocationKind | null,
optional?: boolean,
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[],
typeAnnotation?: K.TSTypeAnnotationKind | null,
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined
}
): namedTypes.TSMethodSignature;
}
export interface TSTypePredicateBuilder {
(
parameterName: K.IdentifierKind | K.TSThisTypeKind,
typeAnnotation?: K.TSTypeAnnotationKind | null,
asserts?: boolean
): namedTypes.TSTypePredicate;
from(
params: {
asserts?: boolean,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
parameterName: K.IdentifierKind | K.TSThisTypeKind,
typeAnnotation?: K.TSTypeAnnotationKind | null
}
): namedTypes.TSTypePredicate;
}
export interface TSCallSignatureDeclarationBuilder {
(
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[],
typeAnnotation?: K.TSTypeAnnotationKind | null
): namedTypes.TSCallSignatureDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[],
typeAnnotation?: K.TSTypeAnnotationKind | null,
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined
}
): namedTypes.TSCallSignatureDeclaration;
}
export interface TSConstructSignatureDeclarationBuilder {
(
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[],
typeAnnotation?: K.TSTypeAnnotationKind | null
): namedTypes.TSConstructSignatureDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[],
typeAnnotation?: K.TSTypeAnnotationKind | null,
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined
}
): namedTypes.TSConstructSignatureDeclaration;
}
export interface TSEnumMemberBuilder {
(
id: K.IdentifierKind | K.StringLiteralKind,
initializer?: K.ExpressionKind | null
): namedTypes.TSEnumMember;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind | K.StringLiteralKind,
initializer?: K.ExpressionKind | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSEnumMember;
}
export interface TSTypeQueryBuilder {
(exprName: K.IdentifierKind | K.TSQualifiedNameKind | K.TSImportTypeKind): namedTypes.TSTypeQuery;
from(
params: {
comments?: K.CommentKind[] | null,
exprName: K.IdentifierKind | K.TSQualifiedNameKind | K.TSImportTypeKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSTypeQuery;
}
export interface TSImportTypeBuilder {
(
argument: K.StringLiteralKind,
qualifier?: K.IdentifierKind | K.TSQualifiedNameKind | undefined,
typeParameters?: K.TSTypeParameterInstantiationKind | null
): namedTypes.TSImportType;
from(
params: {
argument: K.StringLiteralKind,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
qualifier?: K.IdentifierKind | K.TSQualifiedNameKind | undefined,
typeParameters?: K.TSTypeParameterInstantiationKind | null
}
): namedTypes.TSImportType;
}
export interface TSTypeLiteralBuilder {
(
members: (K.TSCallSignatureDeclarationKind | K.TSConstructSignatureDeclarationKind | K.TSIndexSignatureKind | K.TSMethodSignatureKind | K.TSPropertySignatureKind)[]
): namedTypes.TSTypeLiteral;
from(
params: {
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
members: (K.TSCallSignatureDeclarationKind | K.TSConstructSignatureDeclarationKind | K.TSIndexSignatureKind | K.TSMethodSignatureKind | K.TSPropertySignatureKind)[]
}
): namedTypes.TSTypeLiteral;
}
export interface TSTypeAssertionBuilder {
(typeAnnotation: K.TSTypeKind, expression: K.ExpressionKind): namedTypes.TSTypeAssertion;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind,
extra?: {
parenthesized: boolean
} | null,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.TSTypeKind
}
): namedTypes.TSTypeAssertion;
}
export interface TSEnumDeclarationBuilder {
(id: K.IdentifierKind, members: K.TSEnumMemberKind[]): namedTypes.TSEnumDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
const?: boolean,
declare?: boolean,
id: K.IdentifierKind,
initializer?: K.ExpressionKind | null,
loc?: K.SourceLocationKind | null,
members: K.TSEnumMemberKind[]
}
): namedTypes.TSEnumDeclaration;
}
export interface TSTypeAliasDeclarationBuilder {
(id: K.IdentifierKind, typeAnnotation: K.TSTypeKind): namedTypes.TSTypeAliasDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
declare?: boolean,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null,
typeAnnotation: K.TSTypeKind,
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined
}
): namedTypes.TSTypeAliasDeclaration;
}
export interface TSModuleBlockBuilder {
(body: K.StatementKind[]): namedTypes.TSModuleBlock;
from(
params: {
body: K.StatementKind[],
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSModuleBlock;
}
export interface TSModuleDeclarationBuilder {
(
id: K.StringLiteralKind | K.IdentifierKind | K.TSQualifiedNameKind,
body?: K.TSModuleBlockKind | K.TSModuleDeclarationKind | null
): namedTypes.TSModuleDeclaration;
from(
params: {
body?: K.TSModuleBlockKind | K.TSModuleDeclarationKind | null,
comments?: K.CommentKind[] | null,
declare?: boolean,
global?: boolean,
id: K.StringLiteralKind | K.IdentifierKind | K.TSQualifiedNameKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSModuleDeclaration;
}
export interface TSImportEqualsDeclarationBuilder {
(
id: K.IdentifierKind,
moduleReference: K.IdentifierKind | K.TSQualifiedNameKind | K.TSExternalModuleReferenceKind
): namedTypes.TSImportEqualsDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
isExport?: boolean,
loc?: K.SourceLocationKind | null,
moduleReference: K.IdentifierKind | K.TSQualifiedNameKind | K.TSExternalModuleReferenceKind
}
): namedTypes.TSImportEqualsDeclaration;
}
export interface TSExternalModuleReferenceBuilder {
(expression: K.StringLiteralKind): namedTypes.TSExternalModuleReference;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.StringLiteralKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSExternalModuleReference;
}
export interface TSExportAssignmentBuilder {
(expression: K.ExpressionKind): namedTypes.TSExportAssignment;
from(
params: {
comments?: K.CommentKind[] | null,
expression: K.ExpressionKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSExportAssignment;
}
export interface TSNamespaceExportDeclarationBuilder {
(id: K.IdentifierKind): namedTypes.TSNamespaceExportDeclaration;
from(
params: {
comments?: K.CommentKind[] | null,
id: K.IdentifierKind,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSNamespaceExportDeclaration;
}
export interface TSInterfaceBodyBuilder {
(
body: (K.TSCallSignatureDeclarationKind | K.TSConstructSignatureDeclarationKind | K.TSIndexSignatureKind | K.TSMethodSignatureKind | K.TSPropertySignatureKind)[]
): namedTypes.TSInterfaceBody;
from(
params: {
body: (K.TSCallSignatureDeclarationKind | K.TSConstructSignatureDeclarationKind | K.TSIndexSignatureKind | K.TSMethodSignatureKind | K.TSPropertySignatureKind)[],
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null
}
): namedTypes.TSInterfaceBody;
}
export interface TSInterfaceDeclarationBuilder {
(id: K.IdentifierKind | K.TSQualifiedNameKind, body: K.TSInterfaceBodyKind): namedTypes.TSInterfaceDeclaration;
from(
params: {
body: K.TSInterfaceBodyKind,
comments?: K.CommentKind[] | null,
declare?: boolean,
extends?: K.TSExpressionWithTypeArgumentsKind[] | null,
id: K.IdentifierKind | K.TSQualifiedNameKind,
loc?: K.SourceLocationKind | null,
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined
}
): namedTypes.TSInterfaceDeclaration;
}
export interface TSParameterPropertyBuilder {
(parameter: K.IdentifierKind | K.AssignmentPatternKind): namedTypes.TSParameterProperty;
from(
params: {
accessibility?: "public" | "private" | "protected" | undefined,
comments?: K.CommentKind[] | null,
loc?: K.SourceLocationKind | null,
parameter: K.IdentifierKind | K.AssignmentPatternKind,
readonly?: boolean
}
): namedTypes.TSParameterProperty;
}
export interface builders {
file: FileBuilder;
program: ProgramBuilder;
identifier: IdentifierBuilder;
blockStatement: BlockStatementBuilder;
emptyStatement: EmptyStatementBuilder;
expressionStatement: ExpressionStatementBuilder;
ifStatement: IfStatementBuilder;
labeledStatement: LabeledStatementBuilder;
breakStatement: BreakStatementBuilder;
continueStatement: ContinueStatementBuilder;
withStatement: WithStatementBuilder;
switchStatement: SwitchStatementBuilder;
switchCase: SwitchCaseBuilder;
returnStatement: ReturnStatementBuilder;
throwStatement: ThrowStatementBuilder;
tryStatement: TryStatementBuilder;
catchClause: CatchClauseBuilder;
whileStatement: WhileStatementBuilder;
doWhileStatement: DoWhileStatementBuilder;
forStatement: ForStatementBuilder;
variableDeclaration: VariableDeclarationBuilder;
forInStatement: ForInStatementBuilder;
debuggerStatement: DebuggerStatementBuilder;
functionDeclaration: FunctionDeclarationBuilder;
functionExpression: FunctionExpressionBuilder;
variableDeclarator: VariableDeclaratorBuilder;
thisExpression: ThisExpressionBuilder;
arrayExpression: ArrayExpressionBuilder;
objectExpression: ObjectExpressionBuilder;
property: PropertyBuilder;
literal: LiteralBuilder;
sequenceExpression: SequenceExpressionBuilder;
unaryExpression: UnaryExpressionBuilder;
binaryExpression: BinaryExpressionBuilder;
assignmentExpression: AssignmentExpressionBuilder;
memberExpression: MemberExpressionBuilder;
updateExpression: UpdateExpressionBuilder;
logicalExpression: LogicalExpressionBuilder;
conditionalExpression: ConditionalExpressionBuilder;
newExpression: NewExpressionBuilder;
callExpression: CallExpressionBuilder;
restElement: RestElementBuilder;
typeAnnotation: TypeAnnotationBuilder;
tsTypeAnnotation: TSTypeAnnotationBuilder;
spreadElementPattern: SpreadElementPatternBuilder;
arrowFunctionExpression: ArrowFunctionExpressionBuilder;
forOfStatement: ForOfStatementBuilder;
yieldExpression: YieldExpressionBuilder;
generatorExpression: GeneratorExpressionBuilder;
comprehensionBlock: ComprehensionBlockBuilder;
comprehensionExpression: ComprehensionExpressionBuilder;
objectProperty: ObjectPropertyBuilder;
propertyPattern: PropertyPatternBuilder;
objectPattern: ObjectPatternBuilder;
arrayPattern: ArrayPatternBuilder;
spreadElement: SpreadElementBuilder;
assignmentPattern: AssignmentPatternBuilder;
methodDefinition: MethodDefinitionBuilder;
classPropertyDefinition: ClassPropertyDefinitionBuilder;
classProperty: ClassPropertyBuilder;
classBody: ClassBodyBuilder;
classDeclaration: ClassDeclarationBuilder;
classExpression: ClassExpressionBuilder;
super: SuperBuilder;
importSpecifier: ImportSpecifierBuilder;
importDefaultSpecifier: ImportDefaultSpecifierBuilder;
importNamespaceSpecifier: ImportNamespaceSpecifierBuilder;
importDeclaration: ImportDeclarationBuilder;
exportNamedDeclaration: ExportNamedDeclarationBuilder;
exportSpecifier: ExportSpecifierBuilder;
exportDefaultDeclaration: ExportDefaultDeclarationBuilder;
exportAllDeclaration: ExportAllDeclarationBuilder;
taggedTemplateExpression: TaggedTemplateExpressionBuilder;
templateLiteral: TemplateLiteralBuilder;
templateElement: TemplateElementBuilder;
metaProperty: MetaPropertyBuilder;
awaitExpression: AwaitExpressionBuilder;
spreadProperty: SpreadPropertyBuilder;
spreadPropertyPattern: SpreadPropertyPatternBuilder;
importExpression: ImportExpressionBuilder;
chainExpression: ChainExpressionBuilder;
optionalCallExpression: OptionalCallExpressionBuilder;
optionalMemberExpression: OptionalMemberExpressionBuilder;
staticBlock: StaticBlockBuilder;
decorator: DecoratorBuilder;
privateName: PrivateNameBuilder;
classPrivateProperty: ClassPrivatePropertyBuilder;
importAttribute: ImportAttributeBuilder;
recordExpression: RecordExpressionBuilder;
objectMethod: ObjectMethodBuilder;
tupleExpression: TupleExpressionBuilder;
moduleExpression: ModuleExpressionBuilder;
jsxAttribute: JSXAttributeBuilder;
jsxIdentifier: JSXIdentifierBuilder;
jsxNamespacedName: JSXNamespacedNameBuilder;
jsxExpressionContainer: JSXExpressionContainerBuilder;
jsxElement: JSXElementBuilder;
jsxFragment: JSXFragmentBuilder;
jsxMemberExpression: JSXMemberExpressionBuilder;
jsxSpreadAttribute: JSXSpreadAttributeBuilder;
jsxEmptyExpression: JSXEmptyExpressionBuilder;
jsxText: JSXTextBuilder;
jsxSpreadChild: JSXSpreadChildBuilder;
jsxOpeningElement: JSXOpeningElementBuilder;
jsxClosingElement: JSXClosingElementBuilder;
jsxOpeningFragment: JSXOpeningFragmentBuilder;
jsxClosingFragment: JSXClosingFragmentBuilder;
typeParameterDeclaration: TypeParameterDeclarationBuilder;
tsTypeParameterDeclaration: TSTypeParameterDeclarationBuilder;
typeParameterInstantiation: TypeParameterInstantiationBuilder;
tsTypeParameterInstantiation: TSTypeParameterInstantiationBuilder;
classImplements: ClassImplementsBuilder;
tsExpressionWithTypeArguments: TSExpressionWithTypeArgumentsBuilder;
anyTypeAnnotation: AnyTypeAnnotationBuilder;
emptyTypeAnnotation: EmptyTypeAnnotationBuilder;
mixedTypeAnnotation: MixedTypeAnnotationBuilder;
voidTypeAnnotation: VoidTypeAnnotationBuilder;
symbolTypeAnnotation: SymbolTypeAnnotationBuilder;
numberTypeAnnotation: NumberTypeAnnotationBuilder;
bigIntTypeAnnotation: BigIntTypeAnnotationBuilder;
numberLiteralTypeAnnotation: NumberLiteralTypeAnnotationBuilder;
numericLiteralTypeAnnotation: NumericLiteralTypeAnnotationBuilder;
bigIntLiteralTypeAnnotation: BigIntLiteralTypeAnnotationBuilder;
stringTypeAnnotation: StringTypeAnnotationBuilder;
stringLiteralTypeAnnotation: StringLiteralTypeAnnotationBuilder;
booleanTypeAnnotation: BooleanTypeAnnotationBuilder;
booleanLiteralTypeAnnotation: BooleanLiteralTypeAnnotationBuilder;
nullableTypeAnnotation: NullableTypeAnnotationBuilder;
nullLiteralTypeAnnotation: NullLiteralTypeAnnotationBuilder;
nullTypeAnnotation: NullTypeAnnotationBuilder;
thisTypeAnnotation: ThisTypeAnnotationBuilder;
existsTypeAnnotation: ExistsTypeAnnotationBuilder;
existentialTypeParam: ExistentialTypeParamBuilder;
functionTypeAnnotation: FunctionTypeAnnotationBuilder;
functionTypeParam: FunctionTypeParamBuilder;
arrayTypeAnnotation: ArrayTypeAnnotationBuilder;
objectTypeAnnotation: ObjectTypeAnnotationBuilder;
objectTypeProperty: ObjectTypePropertyBuilder;
objectTypeSpreadProperty: ObjectTypeSpreadPropertyBuilder;
objectTypeIndexer: ObjectTypeIndexerBuilder;
objectTypeCallProperty: ObjectTypeCallPropertyBuilder;
objectTypeInternalSlot: ObjectTypeInternalSlotBuilder;
variance: VarianceBuilder;
qualifiedTypeIdentifier: QualifiedTypeIdentifierBuilder;
genericTypeAnnotation: GenericTypeAnnotationBuilder;
memberTypeAnnotation: MemberTypeAnnotationBuilder;
indexedAccessType: IndexedAccessTypeBuilder;
optionalIndexedAccessType: OptionalIndexedAccessTypeBuilder;
unionTypeAnnotation: UnionTypeAnnotationBuilder;
intersectionTypeAnnotation: IntersectionTypeAnnotationBuilder;
typeofTypeAnnotation: TypeofTypeAnnotationBuilder;
typeParameter: TypeParameterBuilder;
interfaceTypeAnnotation: InterfaceTypeAnnotationBuilder;
interfaceExtends: InterfaceExtendsBuilder;
interfaceDeclaration: InterfaceDeclarationBuilder;
declareInterface: DeclareInterfaceBuilder;
typeAlias: TypeAliasBuilder;
declareTypeAlias: DeclareTypeAliasBuilder;
opaqueType: OpaqueTypeBuilder;
declareOpaqueType: DeclareOpaqueTypeBuilder;
typeCastExpression: TypeCastExpressionBuilder;
tupleTypeAnnotation: TupleTypeAnnotationBuilder;
declareVariable: DeclareVariableBuilder;
declareFunction: DeclareFunctionBuilder;
declareClass: DeclareClassBuilder;
declareModule: DeclareModuleBuilder;
declareModuleExports: DeclareModuleExportsBuilder;
declareExportDeclaration: DeclareExportDeclarationBuilder;
exportBatchSpecifier: ExportBatchSpecifierBuilder;
declareExportAllDeclaration: DeclareExportAllDeclarationBuilder;
inferredPredicate: InferredPredicateBuilder;
declaredPredicate: DeclaredPredicateBuilder;
enumDeclaration: EnumDeclarationBuilder;
enumBooleanBody: EnumBooleanBodyBuilder;
enumNumberBody: EnumNumberBodyBuilder;
enumStringBody: EnumStringBodyBuilder;
enumSymbolBody: EnumSymbolBodyBuilder;
enumBooleanMember: EnumBooleanMemberBuilder;
enumNumberMember: EnumNumberMemberBuilder;
enumStringMember: EnumStringMemberBuilder;
enumDefaultedMember: EnumDefaultedMemberBuilder;
exportDeclaration: ExportDeclarationBuilder;
block: BlockBuilder;
line: LineBuilder;
noop: NoopBuilder;
doExpression: DoExpressionBuilder;
bindExpression: BindExpressionBuilder;
parenthesizedExpression: ParenthesizedExpressionBuilder;
exportNamespaceSpecifier: ExportNamespaceSpecifierBuilder;
exportDefaultSpecifier: ExportDefaultSpecifierBuilder;
commentBlock: CommentBlockBuilder;
commentLine: CommentLineBuilder;
directive: DirectiveBuilder;
directiveLiteral: DirectiveLiteralBuilder;
interpreterDirective: InterpreterDirectiveBuilder;
stringLiteral: StringLiteralBuilder;
numericLiteral: NumericLiteralBuilder;
bigIntLiteral: BigIntLiteralBuilder;
decimalLiteral: DecimalLiteralBuilder;
nullLiteral: NullLiteralBuilder;
booleanLiteral: BooleanLiteralBuilder;
regExpLiteral: RegExpLiteralBuilder;
classMethod: ClassMethodBuilder;
classPrivateMethod: ClassPrivateMethodBuilder;
restProperty: RestPropertyBuilder;
forAwaitStatement: ForAwaitStatementBuilder;
import: ImportBuilder;
v8IntrinsicIdentifier: V8IntrinsicIdentifierBuilder;
topicReference: TopicReferenceBuilder;
tsQualifiedName: TSQualifiedNameBuilder;
tsTypeReference: TSTypeReferenceBuilder;
tsAsExpression: TSAsExpressionBuilder;
tsNonNullExpression: TSNonNullExpressionBuilder;
tsAnyKeyword: TSAnyKeywordBuilder;
tsBigIntKeyword: TSBigIntKeywordBuilder;
tsBooleanKeyword: TSBooleanKeywordBuilder;
tsNeverKeyword: TSNeverKeywordBuilder;
tsNullKeyword: TSNullKeywordBuilder;
tsNumberKeyword: TSNumberKeywordBuilder;
tsObjectKeyword: TSObjectKeywordBuilder;
tsStringKeyword: TSStringKeywordBuilder;
tsSymbolKeyword: TSSymbolKeywordBuilder;
tsUndefinedKeyword: TSUndefinedKeywordBuilder;
tsUnknownKeyword: TSUnknownKeywordBuilder;
tsVoidKeyword: TSVoidKeywordBuilder;
tsIntrinsicKeyword: TSIntrinsicKeywordBuilder;
tsThisType: TSThisTypeBuilder;
tsArrayType: TSArrayTypeBuilder;
tsLiteralType: TSLiteralTypeBuilder;
tsUnionType: TSUnionTypeBuilder;
tsIntersectionType: TSIntersectionTypeBuilder;
tsConditionalType: TSConditionalTypeBuilder;
tsInferType: TSInferTypeBuilder;
tsTypeParameter: TSTypeParameterBuilder;
tsParenthesizedType: TSParenthesizedTypeBuilder;
tsFunctionType: TSFunctionTypeBuilder;
tsConstructorType: TSConstructorTypeBuilder;
tsDeclareFunction: TSDeclareFunctionBuilder;
tsDeclareMethod: TSDeclareMethodBuilder;
tsMappedType: TSMappedTypeBuilder;
tsTupleType: TSTupleTypeBuilder;
tsNamedTupleMember: TSNamedTupleMemberBuilder;
tsRestType: TSRestTypeBuilder;
tsOptionalType: TSOptionalTypeBuilder;
tsIndexedAccessType: TSIndexedAccessTypeBuilder;
tsTypeOperator: TSTypeOperatorBuilder;
tsIndexSignature: TSIndexSignatureBuilder;
tsPropertySignature: TSPropertySignatureBuilder;
tsMethodSignature: TSMethodSignatureBuilder;
tsTypePredicate: TSTypePredicateBuilder;
tsCallSignatureDeclaration: TSCallSignatureDeclarationBuilder;
tsConstructSignatureDeclaration: TSConstructSignatureDeclarationBuilder;
tsEnumMember: TSEnumMemberBuilder;
tsTypeQuery: TSTypeQueryBuilder;
tsImportType: TSImportTypeBuilder;
tsTypeLiteral: TSTypeLiteralBuilder;
tsTypeAssertion: TSTypeAssertionBuilder;
tsEnumDeclaration: TSEnumDeclarationBuilder;
tsTypeAliasDeclaration: TSTypeAliasDeclarationBuilder;
tsModuleBlock: TSModuleBlockBuilder;
tsModuleDeclaration: TSModuleDeclarationBuilder;
tsImportEqualsDeclaration: TSImportEqualsDeclarationBuilder;
tsExternalModuleReference: TSExternalModuleReferenceBuilder;
tsExportAssignment: TSExportAssignmentBuilder;
tsNamespaceExportDeclaration: TSNamespaceExportDeclarationBuilder;
tsInterfaceBody: TSInterfaceBodyBuilder;
tsInterfaceDeclaration: TSInterfaceDeclarationBuilder;
tsParameterProperty: TSParameterPropertyBuilder;
[builderName: string]: any;
}ast-types-0.15.2/gen/kinds.ts000066400000000000000000001277151415222403600157750ustar00rootroot00000000000000/* !!! THIS FILE WAS AUTO-GENERATED BY `npm run gen` !!! */
import { namedTypes } from "./namedTypes";
export type PrintableKind = namedTypes.File | namedTypes.Program | namedTypes.Identifier | namedTypes.BlockStatement | namedTypes.EmptyStatement | namedTypes.ExpressionStatement | namedTypes.IfStatement | namedTypes.LabeledStatement | namedTypes.BreakStatement | namedTypes.ContinueStatement | namedTypes.WithStatement | namedTypes.SwitchStatement | namedTypes.SwitchCase | namedTypes.ReturnStatement | namedTypes.ThrowStatement | namedTypes.TryStatement | namedTypes.CatchClause | namedTypes.WhileStatement | namedTypes.DoWhileStatement | namedTypes.ForStatement | namedTypes.VariableDeclaration | namedTypes.ForInStatement | namedTypes.DebuggerStatement | namedTypes.FunctionDeclaration | namedTypes.FunctionExpression | namedTypes.VariableDeclarator | namedTypes.ThisExpression | namedTypes.ArrayExpression | namedTypes.ObjectExpression | namedTypes.Property | namedTypes.Literal | namedTypes.SequenceExpression | namedTypes.UnaryExpression | namedTypes.BinaryExpression | namedTypes.AssignmentExpression | namedTypes.MemberExpression | namedTypes.UpdateExpression | namedTypes.LogicalExpression | namedTypes.ConditionalExpression | namedTypes.NewExpression | namedTypes.CallExpression | namedTypes.RestElement | namedTypes.TypeAnnotation | namedTypes.TSTypeAnnotation | namedTypes.SpreadElementPattern | namedTypes.ArrowFunctionExpression | namedTypes.ForOfStatement | namedTypes.YieldExpression | namedTypes.GeneratorExpression | namedTypes.ComprehensionBlock | namedTypes.ComprehensionExpression | namedTypes.ObjectProperty | namedTypes.PropertyPattern | namedTypes.ObjectPattern | namedTypes.ArrayPattern | namedTypes.SpreadElement | namedTypes.AssignmentPattern | namedTypes.MethodDefinition | namedTypes.ClassPropertyDefinition | namedTypes.ClassProperty | namedTypes.ClassBody | namedTypes.ClassDeclaration | namedTypes.ClassExpression | namedTypes.Super | namedTypes.ImportSpecifier | namedTypes.ImportDefaultSpecifier | namedTypes.ImportNamespaceSpecifier | namedTypes.ImportDeclaration | namedTypes.ExportNamedDeclaration | namedTypes.ExportSpecifier | namedTypes.ExportDefaultDeclaration | namedTypes.ExportAllDeclaration | namedTypes.TaggedTemplateExpression | namedTypes.TemplateLiteral | namedTypes.TemplateElement | namedTypes.MetaProperty | namedTypes.AwaitExpression | namedTypes.SpreadProperty | namedTypes.SpreadPropertyPattern | namedTypes.ImportExpression | namedTypes.ChainExpression | namedTypes.OptionalCallExpression | namedTypes.OptionalMemberExpression | namedTypes.StaticBlock | namedTypes.Decorator | namedTypes.PrivateName | namedTypes.ClassPrivateProperty | namedTypes.ImportAttribute | namedTypes.RecordExpression | namedTypes.ObjectMethod | namedTypes.TupleExpression | namedTypes.ModuleExpression | namedTypes.JSXAttribute | namedTypes.JSXIdentifier | namedTypes.JSXNamespacedName | namedTypes.JSXExpressionContainer | namedTypes.JSXElement | namedTypes.JSXFragment | namedTypes.JSXMemberExpression | namedTypes.JSXSpreadAttribute | namedTypes.JSXEmptyExpression | namedTypes.JSXText | namedTypes.JSXSpreadChild | namedTypes.JSXOpeningElement | namedTypes.JSXClosingElement | namedTypes.JSXOpeningFragment | namedTypes.JSXClosingFragment | namedTypes.TypeParameterDeclaration | namedTypes.TSTypeParameterDeclaration | namedTypes.TypeParameterInstantiation | namedTypes.TSTypeParameterInstantiation | namedTypes.ClassImplements | namedTypes.TSExpressionWithTypeArguments | namedTypes.AnyTypeAnnotation | namedTypes.EmptyTypeAnnotation | namedTypes.MixedTypeAnnotation | namedTypes.VoidTypeAnnotation | namedTypes.SymbolTypeAnnotation | namedTypes.NumberTypeAnnotation | namedTypes.BigIntTypeAnnotation | namedTypes.NumberLiteralTypeAnnotation | namedTypes.NumericLiteralTypeAnnotation | namedTypes.BigIntLiteralTypeAnnotation | namedTypes.StringTypeAnnotation | namedTypes.StringLiteralTypeAnnotation | namedTypes.BooleanTypeAnnotation | namedTypes.BooleanLiteralTypeAnnotation | namedTypes.NullableTypeAnnotation | namedTypes.NullLiteralTypeAnnotation | namedTypes.NullTypeAnnotation | namedTypes.ThisTypeAnnotation | namedTypes.ExistsTypeAnnotation | namedTypes.ExistentialTypeParam | namedTypes.FunctionTypeAnnotation | namedTypes.FunctionTypeParam | namedTypes.ArrayTypeAnnotation | namedTypes.ObjectTypeAnnotation | namedTypes.ObjectTypeProperty | namedTypes.ObjectTypeSpreadProperty | namedTypes.ObjectTypeIndexer | namedTypes.ObjectTypeCallProperty | namedTypes.ObjectTypeInternalSlot | namedTypes.Variance | namedTypes.QualifiedTypeIdentifier | namedTypes.GenericTypeAnnotation | namedTypes.MemberTypeAnnotation | namedTypes.IndexedAccessType | namedTypes.OptionalIndexedAccessType | namedTypes.UnionTypeAnnotation | namedTypes.IntersectionTypeAnnotation | namedTypes.TypeofTypeAnnotation | namedTypes.TypeParameter | namedTypes.InterfaceTypeAnnotation | namedTypes.InterfaceExtends | namedTypes.InterfaceDeclaration | namedTypes.DeclareInterface | namedTypes.TypeAlias | namedTypes.DeclareTypeAlias | namedTypes.OpaqueType | namedTypes.DeclareOpaqueType | namedTypes.TypeCastExpression | namedTypes.TupleTypeAnnotation | namedTypes.DeclareVariable | namedTypes.DeclareFunction | namedTypes.DeclareClass | namedTypes.DeclareModule | namedTypes.DeclareModuleExports | namedTypes.DeclareExportDeclaration | namedTypes.ExportBatchSpecifier | namedTypes.DeclareExportAllDeclaration | namedTypes.InferredPredicate | namedTypes.DeclaredPredicate | namedTypes.EnumDeclaration | namedTypes.ExportDeclaration | namedTypes.Block | namedTypes.Line | namedTypes.Noop | namedTypes.DoExpression | namedTypes.BindExpression | namedTypes.ParenthesizedExpression | namedTypes.ExportNamespaceSpecifier | namedTypes.ExportDefaultSpecifier | namedTypes.CommentBlock | namedTypes.CommentLine | namedTypes.Directive | namedTypes.DirectiveLiteral | namedTypes.InterpreterDirective | namedTypes.StringLiteral | namedTypes.NumericLiteral | namedTypes.BigIntLiteral | namedTypes.DecimalLiteral | namedTypes.NullLiteral | namedTypes.BooleanLiteral | namedTypes.RegExpLiteral | namedTypes.ClassMethod | namedTypes.ClassPrivateMethod | namedTypes.RestProperty | namedTypes.ForAwaitStatement | namedTypes.Import | namedTypes.V8IntrinsicIdentifier | namedTypes.TopicReference | namedTypes.TSQualifiedName | namedTypes.TSTypeReference | namedTypes.TSAsExpression | namedTypes.TSNonNullExpression | namedTypes.TSAnyKeyword | namedTypes.TSBigIntKeyword | namedTypes.TSBooleanKeyword | namedTypes.TSNeverKeyword | namedTypes.TSNullKeyword | namedTypes.TSNumberKeyword | namedTypes.TSObjectKeyword | namedTypes.TSStringKeyword | namedTypes.TSSymbolKeyword | namedTypes.TSUndefinedKeyword | namedTypes.TSUnknownKeyword | namedTypes.TSVoidKeyword | namedTypes.TSIntrinsicKeyword | namedTypes.TSThisType | namedTypes.TSArrayType | namedTypes.TSLiteralType | namedTypes.TSUnionType | namedTypes.TSIntersectionType | namedTypes.TSConditionalType | namedTypes.TSInferType | namedTypes.TSTypeParameter | namedTypes.TSParenthesizedType | namedTypes.TSFunctionType | namedTypes.TSConstructorType | namedTypes.TSDeclareFunction | namedTypes.TSDeclareMethod | namedTypes.TSMappedType | namedTypes.TSTupleType | namedTypes.TSNamedTupleMember | namedTypes.TSRestType | namedTypes.TSOptionalType | namedTypes.TSIndexedAccessType | namedTypes.TSTypeOperator | namedTypes.TSIndexSignature | namedTypes.TSPropertySignature | namedTypes.TSMethodSignature | namedTypes.TSTypePredicate | namedTypes.TSCallSignatureDeclaration | namedTypes.TSConstructSignatureDeclaration | namedTypes.TSEnumMember | namedTypes.TSTypeQuery | namedTypes.TSImportType | namedTypes.TSTypeLiteral | namedTypes.TSTypeAssertion | namedTypes.TSEnumDeclaration | namedTypes.TSTypeAliasDeclaration | namedTypes.TSModuleBlock | namedTypes.TSModuleDeclaration | namedTypes.TSImportEqualsDeclaration | namedTypes.TSExternalModuleReference | namedTypes.TSExportAssignment | namedTypes.TSNamespaceExportDeclaration | namedTypes.TSInterfaceBody | namedTypes.TSInterfaceDeclaration | namedTypes.TSParameterProperty;
export type SourceLocationKind = namedTypes.SourceLocation;
export type NodeKind = namedTypes.File | namedTypes.Program | namedTypes.Identifier | namedTypes.BlockStatement | namedTypes.EmptyStatement | namedTypes.ExpressionStatement | namedTypes.IfStatement | namedTypes.LabeledStatement | namedTypes.BreakStatement | namedTypes.ContinueStatement | namedTypes.WithStatement | namedTypes.SwitchStatement | namedTypes.SwitchCase | namedTypes.ReturnStatement | namedTypes.ThrowStatement | namedTypes.TryStatement | namedTypes.CatchClause | namedTypes.WhileStatement | namedTypes.DoWhileStatement | namedTypes.ForStatement | namedTypes.VariableDeclaration | namedTypes.ForInStatement | namedTypes.DebuggerStatement | namedTypes.FunctionDeclaration | namedTypes.FunctionExpression | namedTypes.VariableDeclarator | namedTypes.ThisExpression | namedTypes.ArrayExpression | namedTypes.ObjectExpression | namedTypes.Property | namedTypes.Literal | namedTypes.SequenceExpression | namedTypes.UnaryExpression | namedTypes.BinaryExpression | namedTypes.AssignmentExpression | namedTypes.MemberExpression | namedTypes.UpdateExpression | namedTypes.LogicalExpression | namedTypes.ConditionalExpression | namedTypes.NewExpression | namedTypes.CallExpression | namedTypes.RestElement | namedTypes.TypeAnnotation | namedTypes.TSTypeAnnotation | namedTypes.SpreadElementPattern | namedTypes.ArrowFunctionExpression | namedTypes.ForOfStatement | namedTypes.YieldExpression | namedTypes.GeneratorExpression | namedTypes.ComprehensionBlock | namedTypes.ComprehensionExpression | namedTypes.ObjectProperty | namedTypes.PropertyPattern | namedTypes.ObjectPattern | namedTypes.ArrayPattern | namedTypes.SpreadElement | namedTypes.AssignmentPattern | namedTypes.MethodDefinition | namedTypes.ClassPropertyDefinition | namedTypes.ClassProperty | namedTypes.ClassBody | namedTypes.ClassDeclaration | namedTypes.ClassExpression | namedTypes.Super | namedTypes.ImportSpecifier | namedTypes.ImportDefaultSpecifier | namedTypes.ImportNamespaceSpecifier | namedTypes.ImportDeclaration | namedTypes.ExportNamedDeclaration | namedTypes.ExportSpecifier | namedTypes.ExportDefaultDeclaration | namedTypes.ExportAllDeclaration | namedTypes.TaggedTemplateExpression | namedTypes.TemplateLiteral | namedTypes.TemplateElement | namedTypes.MetaProperty | namedTypes.AwaitExpression | namedTypes.SpreadProperty | namedTypes.SpreadPropertyPattern | namedTypes.ImportExpression | namedTypes.ChainExpression | namedTypes.OptionalCallExpression | namedTypes.OptionalMemberExpression | namedTypes.StaticBlock | namedTypes.Decorator | namedTypes.PrivateName | namedTypes.ClassPrivateProperty | namedTypes.ImportAttribute | namedTypes.RecordExpression | namedTypes.ObjectMethod | namedTypes.TupleExpression | namedTypes.ModuleExpression | namedTypes.JSXAttribute | namedTypes.JSXIdentifier | namedTypes.JSXNamespacedName | namedTypes.JSXExpressionContainer | namedTypes.JSXElement | namedTypes.JSXFragment | namedTypes.JSXMemberExpression | namedTypes.JSXSpreadAttribute | namedTypes.JSXEmptyExpression | namedTypes.JSXText | namedTypes.JSXSpreadChild | namedTypes.JSXOpeningElement | namedTypes.JSXClosingElement | namedTypes.JSXOpeningFragment | namedTypes.JSXClosingFragment | namedTypes.TypeParameterDeclaration | namedTypes.TSTypeParameterDeclaration | namedTypes.TypeParameterInstantiation | namedTypes.TSTypeParameterInstantiation | namedTypes.ClassImplements | namedTypes.TSExpressionWithTypeArguments | namedTypes.AnyTypeAnnotation | namedTypes.EmptyTypeAnnotation | namedTypes.MixedTypeAnnotation | namedTypes.VoidTypeAnnotation | namedTypes.SymbolTypeAnnotation | namedTypes.NumberTypeAnnotation | namedTypes.BigIntTypeAnnotation | namedTypes.NumberLiteralTypeAnnotation | namedTypes.NumericLiteralTypeAnnotation | namedTypes.BigIntLiteralTypeAnnotation | namedTypes.StringTypeAnnotation | namedTypes.StringLiteralTypeAnnotation | namedTypes.BooleanTypeAnnotation | namedTypes.BooleanLiteralTypeAnnotation | namedTypes.NullableTypeAnnotation | namedTypes.NullLiteralTypeAnnotation | namedTypes.NullTypeAnnotation | namedTypes.ThisTypeAnnotation | namedTypes.ExistsTypeAnnotation | namedTypes.ExistentialTypeParam | namedTypes.FunctionTypeAnnotation | namedTypes.FunctionTypeParam | namedTypes.ArrayTypeAnnotation | namedTypes.ObjectTypeAnnotation | namedTypes.ObjectTypeProperty | namedTypes.ObjectTypeSpreadProperty | namedTypes.ObjectTypeIndexer | namedTypes.ObjectTypeCallProperty | namedTypes.ObjectTypeInternalSlot | namedTypes.Variance | namedTypes.QualifiedTypeIdentifier | namedTypes.GenericTypeAnnotation | namedTypes.MemberTypeAnnotation | namedTypes.IndexedAccessType | namedTypes.OptionalIndexedAccessType | namedTypes.UnionTypeAnnotation | namedTypes.IntersectionTypeAnnotation | namedTypes.TypeofTypeAnnotation | namedTypes.TypeParameter | namedTypes.InterfaceTypeAnnotation | namedTypes.InterfaceExtends | namedTypes.InterfaceDeclaration | namedTypes.DeclareInterface | namedTypes.TypeAlias | namedTypes.DeclareTypeAlias | namedTypes.OpaqueType | namedTypes.DeclareOpaqueType | namedTypes.TypeCastExpression | namedTypes.TupleTypeAnnotation | namedTypes.DeclareVariable | namedTypes.DeclareFunction | namedTypes.DeclareClass | namedTypes.DeclareModule | namedTypes.DeclareModuleExports | namedTypes.DeclareExportDeclaration | namedTypes.ExportBatchSpecifier | namedTypes.DeclareExportAllDeclaration | namedTypes.InferredPredicate | namedTypes.DeclaredPredicate | namedTypes.EnumDeclaration | namedTypes.ExportDeclaration | namedTypes.Noop | namedTypes.DoExpression | namedTypes.BindExpression | namedTypes.ParenthesizedExpression | namedTypes.ExportNamespaceSpecifier | namedTypes.ExportDefaultSpecifier | namedTypes.Directive | namedTypes.DirectiveLiteral | namedTypes.InterpreterDirective | namedTypes.StringLiteral | namedTypes.NumericLiteral | namedTypes.BigIntLiteral | namedTypes.DecimalLiteral | namedTypes.NullLiteral | namedTypes.BooleanLiteral | namedTypes.RegExpLiteral | namedTypes.ClassMethod | namedTypes.ClassPrivateMethod | namedTypes.RestProperty | namedTypes.ForAwaitStatement | namedTypes.Import | namedTypes.V8IntrinsicIdentifier | namedTypes.TopicReference | namedTypes.TSQualifiedName | namedTypes.TSTypeReference | namedTypes.TSAsExpression | namedTypes.TSNonNullExpression | namedTypes.TSAnyKeyword | namedTypes.TSBigIntKeyword | namedTypes.TSBooleanKeyword | namedTypes.TSNeverKeyword | namedTypes.TSNullKeyword | namedTypes.TSNumberKeyword | namedTypes.TSObjectKeyword | namedTypes.TSStringKeyword | namedTypes.TSSymbolKeyword | namedTypes.TSUndefinedKeyword | namedTypes.TSUnknownKeyword | namedTypes.TSVoidKeyword | namedTypes.TSIntrinsicKeyword | namedTypes.TSThisType | namedTypes.TSArrayType | namedTypes.TSLiteralType | namedTypes.TSUnionType | namedTypes.TSIntersectionType | namedTypes.TSConditionalType | namedTypes.TSInferType | namedTypes.TSTypeParameter | namedTypes.TSParenthesizedType | namedTypes.TSFunctionType | namedTypes.TSConstructorType | namedTypes.TSDeclareFunction | namedTypes.TSDeclareMethod | namedTypes.TSMappedType | namedTypes.TSTupleType | namedTypes.TSNamedTupleMember | namedTypes.TSRestType | namedTypes.TSOptionalType | namedTypes.TSIndexedAccessType | namedTypes.TSTypeOperator | namedTypes.TSIndexSignature | namedTypes.TSPropertySignature | namedTypes.TSMethodSignature | namedTypes.TSTypePredicate | namedTypes.TSCallSignatureDeclaration | namedTypes.TSConstructSignatureDeclaration | namedTypes.TSEnumMember | namedTypes.TSTypeQuery | namedTypes.TSImportType | namedTypes.TSTypeLiteral | namedTypes.TSTypeAssertion | namedTypes.TSEnumDeclaration | namedTypes.TSTypeAliasDeclaration | namedTypes.TSModuleBlock | namedTypes.TSModuleDeclaration | namedTypes.TSImportEqualsDeclaration | namedTypes.TSExternalModuleReference | namedTypes.TSExportAssignment | namedTypes.TSNamespaceExportDeclaration | namedTypes.TSInterfaceBody | namedTypes.TSInterfaceDeclaration | namedTypes.TSParameterProperty;
export type CommentKind = namedTypes.Block | namedTypes.Line | namedTypes.CommentBlock | namedTypes.CommentLine;
export type PositionKind = namedTypes.Position;
export type FileKind = namedTypes.File;
export type ProgramKind = namedTypes.Program;
export type StatementKind = namedTypes.BlockStatement | namedTypes.EmptyStatement | namedTypes.ExpressionStatement | namedTypes.IfStatement | namedTypes.LabeledStatement | namedTypes.BreakStatement | namedTypes.ContinueStatement | namedTypes.WithStatement | namedTypes.SwitchStatement | namedTypes.ReturnStatement | namedTypes.ThrowStatement | namedTypes.TryStatement | namedTypes.WhileStatement | namedTypes.DoWhileStatement | namedTypes.ForStatement | namedTypes.VariableDeclaration | namedTypes.ForInStatement | namedTypes.DebuggerStatement | namedTypes.FunctionDeclaration | namedTypes.ForOfStatement | namedTypes.MethodDefinition | namedTypes.ClassPropertyDefinition | namedTypes.ClassProperty | namedTypes.ClassBody | namedTypes.ClassDeclaration | namedTypes.ImportDeclaration | namedTypes.ExportNamedDeclaration | namedTypes.ExportDefaultDeclaration | namedTypes.ExportAllDeclaration | namedTypes.StaticBlock | namedTypes.ClassPrivateProperty | namedTypes.TSTypeParameterDeclaration | namedTypes.InterfaceDeclaration | namedTypes.DeclareInterface | namedTypes.TypeAlias | namedTypes.DeclareTypeAlias | namedTypes.OpaqueType | namedTypes.DeclareOpaqueType | namedTypes.DeclareVariable | namedTypes.DeclareFunction | namedTypes.DeclareClass | namedTypes.DeclareModule | namedTypes.DeclareModuleExports | namedTypes.DeclareExportDeclaration | namedTypes.DeclareExportAllDeclaration | namedTypes.EnumDeclaration | namedTypes.ExportDeclaration | namedTypes.Noop | namedTypes.ClassMethod | namedTypes.ClassPrivateMethod | namedTypes.ForAwaitStatement | namedTypes.TSDeclareFunction | namedTypes.TSDeclareMethod | namedTypes.TSIndexSignature | namedTypes.TSPropertySignature | namedTypes.TSMethodSignature | namedTypes.TSCallSignatureDeclaration | namedTypes.TSConstructSignatureDeclaration | namedTypes.TSEnumDeclaration | namedTypes.TSTypeAliasDeclaration | namedTypes.TSModuleDeclaration | namedTypes.TSImportEqualsDeclaration | namedTypes.TSExternalModuleReference | namedTypes.TSExportAssignment | namedTypes.TSNamespaceExportDeclaration | namedTypes.TSInterfaceDeclaration;
export type FunctionKind = namedTypes.FunctionDeclaration | namedTypes.FunctionExpression | namedTypes.ArrowFunctionExpression | namedTypes.ObjectMethod | namedTypes.ClassMethod | namedTypes.ClassPrivateMethod;
export type ExpressionKind = namedTypes.Identifier | namedTypes.FunctionExpression | namedTypes.ThisExpression | namedTypes.ArrayExpression | namedTypes.ObjectExpression | namedTypes.Literal | namedTypes.SequenceExpression | namedTypes.UnaryExpression | namedTypes.BinaryExpression | namedTypes.AssignmentExpression | namedTypes.MemberExpression | namedTypes.UpdateExpression | namedTypes.LogicalExpression | namedTypes.ConditionalExpression | namedTypes.NewExpression | namedTypes.CallExpression | namedTypes.ArrowFunctionExpression | namedTypes.YieldExpression | namedTypes.GeneratorExpression | namedTypes.ComprehensionExpression | namedTypes.ClassExpression | namedTypes.Super | namedTypes.TaggedTemplateExpression | namedTypes.TemplateLiteral | namedTypes.MetaProperty | namedTypes.AwaitExpression | namedTypes.ImportExpression | namedTypes.ChainExpression | namedTypes.OptionalCallExpression | namedTypes.OptionalMemberExpression | namedTypes.PrivateName | namedTypes.RecordExpression | namedTypes.TupleExpression | namedTypes.JSXIdentifier | namedTypes.JSXExpressionContainer | namedTypes.JSXElement | namedTypes.JSXFragment | namedTypes.JSXMemberExpression | namedTypes.JSXText | namedTypes.TypeCastExpression | namedTypes.DoExpression | namedTypes.BindExpression | namedTypes.ParenthesizedExpression | namedTypes.DirectiveLiteral | namedTypes.StringLiteral | namedTypes.NumericLiteral | namedTypes.BigIntLiteral | namedTypes.DecimalLiteral | namedTypes.NullLiteral | namedTypes.BooleanLiteral | namedTypes.RegExpLiteral | namedTypes.Import | namedTypes.V8IntrinsicIdentifier | namedTypes.TopicReference | namedTypes.TSAsExpression | namedTypes.TSNonNullExpression | namedTypes.TSTypeParameter | namedTypes.TSTypeAssertion;
export type PatternKind = namedTypes.Identifier | namedTypes.RestElement | namedTypes.SpreadElementPattern | namedTypes.PropertyPattern | namedTypes.ObjectPattern | namedTypes.ArrayPattern | namedTypes.AssignmentPattern | namedTypes.SpreadPropertyPattern | namedTypes.PrivateName | namedTypes.JSXIdentifier | namedTypes.TSAsExpression | namedTypes.TSNonNullExpression | namedTypes.TSTypeParameter | namedTypes.TSTypeAssertion | namedTypes.TSParameterProperty;
export type IdentifierKind = namedTypes.Identifier | namedTypes.JSXIdentifier | namedTypes.TSTypeParameter;
export type BlockStatementKind = namedTypes.BlockStatement;
export type EmptyStatementKind = namedTypes.EmptyStatement;
export type ExpressionStatementKind = namedTypes.ExpressionStatement;
export type IfStatementKind = namedTypes.IfStatement;
export type LabeledStatementKind = namedTypes.LabeledStatement;
export type BreakStatementKind = namedTypes.BreakStatement;
export type ContinueStatementKind = namedTypes.ContinueStatement;
export type WithStatementKind = namedTypes.WithStatement;
export type SwitchStatementKind = namedTypes.SwitchStatement;
export type SwitchCaseKind = namedTypes.SwitchCase;
export type ReturnStatementKind = namedTypes.ReturnStatement;
export type ThrowStatementKind = namedTypes.ThrowStatement;
export type TryStatementKind = namedTypes.TryStatement;
export type CatchClauseKind = namedTypes.CatchClause;
export type WhileStatementKind = namedTypes.WhileStatement;
export type DoWhileStatementKind = namedTypes.DoWhileStatement;
export type ForStatementKind = namedTypes.ForStatement;
export type DeclarationKind = namedTypes.VariableDeclaration | namedTypes.FunctionDeclaration | namedTypes.MethodDefinition | namedTypes.ClassPropertyDefinition | namedTypes.ClassProperty | namedTypes.ClassBody | namedTypes.ClassDeclaration | namedTypes.ImportDeclaration | namedTypes.ExportNamedDeclaration | namedTypes.ExportDefaultDeclaration | namedTypes.ExportAllDeclaration | namedTypes.StaticBlock | namedTypes.ClassPrivateProperty | namedTypes.TSTypeParameterDeclaration | namedTypes.InterfaceDeclaration | namedTypes.DeclareInterface | namedTypes.TypeAlias | namedTypes.DeclareTypeAlias | namedTypes.OpaqueType | namedTypes.DeclareOpaqueType | namedTypes.DeclareClass | namedTypes.DeclareExportDeclaration | namedTypes.DeclareExportAllDeclaration | namedTypes.EnumDeclaration | namedTypes.ExportDeclaration | namedTypes.ClassMethod | namedTypes.ClassPrivateMethod | namedTypes.TSDeclareFunction | namedTypes.TSDeclareMethod | namedTypes.TSIndexSignature | namedTypes.TSPropertySignature | namedTypes.TSMethodSignature | namedTypes.TSCallSignatureDeclaration | namedTypes.TSConstructSignatureDeclaration | namedTypes.TSEnumDeclaration | namedTypes.TSTypeAliasDeclaration | namedTypes.TSModuleDeclaration | namedTypes.TSImportEqualsDeclaration | namedTypes.TSExternalModuleReference | namedTypes.TSNamespaceExportDeclaration | namedTypes.TSInterfaceDeclaration;
export type VariableDeclarationKind = namedTypes.VariableDeclaration;
export type ForInStatementKind = namedTypes.ForInStatement;
export type DebuggerStatementKind = namedTypes.DebuggerStatement;
export type FunctionDeclarationKind = namedTypes.FunctionDeclaration;
export type FunctionExpressionKind = namedTypes.FunctionExpression;
export type VariableDeclaratorKind = namedTypes.VariableDeclarator;
export type ThisExpressionKind = namedTypes.ThisExpression;
export type ArrayExpressionKind = namedTypes.ArrayExpression;
export type ObjectExpressionKind = namedTypes.ObjectExpression;
export type PropertyKind = namedTypes.Property;
export type LiteralKind = namedTypes.Literal | namedTypes.JSXText | namedTypes.StringLiteral | namedTypes.NumericLiteral | namedTypes.BigIntLiteral | namedTypes.DecimalLiteral | namedTypes.NullLiteral | namedTypes.BooleanLiteral | namedTypes.RegExpLiteral;
export type SequenceExpressionKind = namedTypes.SequenceExpression;
export type UnaryExpressionKind = namedTypes.UnaryExpression;
export type BinaryExpressionKind = namedTypes.BinaryExpression;
export type AssignmentExpressionKind = namedTypes.AssignmentExpression;
export type ChainElementKind = namedTypes.MemberExpression | namedTypes.CallExpression | namedTypes.OptionalCallExpression | namedTypes.OptionalMemberExpression | namedTypes.JSXMemberExpression;
export type MemberExpressionKind = namedTypes.MemberExpression | namedTypes.OptionalMemberExpression | namedTypes.JSXMemberExpression;
export type UpdateExpressionKind = namedTypes.UpdateExpression;
export type LogicalExpressionKind = namedTypes.LogicalExpression;
export type ConditionalExpressionKind = namedTypes.ConditionalExpression;
export type NewExpressionKind = namedTypes.NewExpression;
export type CallExpressionKind = namedTypes.CallExpression | namedTypes.OptionalCallExpression;
export type RestElementKind = namedTypes.RestElement;
export type TypeAnnotationKind = namedTypes.TypeAnnotation;
export type TSTypeAnnotationKind = namedTypes.TSTypeAnnotation | namedTypes.TSTypePredicate;
export type SpreadElementPatternKind = namedTypes.SpreadElementPattern;
export type ArrowFunctionExpressionKind = namedTypes.ArrowFunctionExpression;
export type ForOfStatementKind = namedTypes.ForOfStatement;
export type YieldExpressionKind = namedTypes.YieldExpression;
export type GeneratorExpressionKind = namedTypes.GeneratorExpression;
export type ComprehensionBlockKind = namedTypes.ComprehensionBlock;
export type ComprehensionExpressionKind = namedTypes.ComprehensionExpression;
export type ObjectPropertyKind = namedTypes.ObjectProperty;
export type PropertyPatternKind = namedTypes.PropertyPattern;
export type ObjectPatternKind = namedTypes.ObjectPattern;
export type ArrayPatternKind = namedTypes.ArrayPattern;
export type SpreadElementKind = namedTypes.SpreadElement;
export type AssignmentPatternKind = namedTypes.AssignmentPattern;
export type MethodDefinitionKind = namedTypes.MethodDefinition;
export type ClassPropertyDefinitionKind = namedTypes.ClassPropertyDefinition;
export type ClassPropertyKind = namedTypes.ClassProperty | namedTypes.ClassPrivateProperty;
export type ClassBodyKind = namedTypes.ClassBody;
export type ClassDeclarationKind = namedTypes.ClassDeclaration;
export type ClassExpressionKind = namedTypes.ClassExpression;
export type SuperKind = namedTypes.Super;
export type SpecifierKind = namedTypes.ImportSpecifier | namedTypes.ImportDefaultSpecifier | namedTypes.ImportNamespaceSpecifier | namedTypes.ExportSpecifier | namedTypes.ExportBatchSpecifier | namedTypes.ExportNamespaceSpecifier | namedTypes.ExportDefaultSpecifier;
export type ModuleSpecifierKind = namedTypes.ImportSpecifier | namedTypes.ImportDefaultSpecifier | namedTypes.ImportNamespaceSpecifier | namedTypes.ExportSpecifier;
export type ImportSpecifierKind = namedTypes.ImportSpecifier;
export type ImportDefaultSpecifierKind = namedTypes.ImportDefaultSpecifier;
export type ImportNamespaceSpecifierKind = namedTypes.ImportNamespaceSpecifier;
export type ImportDeclarationKind = namedTypes.ImportDeclaration;
export type ExportNamedDeclarationKind = namedTypes.ExportNamedDeclaration;
export type ExportSpecifierKind = namedTypes.ExportSpecifier;
export type ExportDefaultDeclarationKind = namedTypes.ExportDefaultDeclaration;
export type ExportAllDeclarationKind = namedTypes.ExportAllDeclaration;
export type TaggedTemplateExpressionKind = namedTypes.TaggedTemplateExpression;
export type TemplateLiteralKind = namedTypes.TemplateLiteral;
export type TemplateElementKind = namedTypes.TemplateElement;
export type MetaPropertyKind = namedTypes.MetaProperty;
export type AwaitExpressionKind = namedTypes.AwaitExpression;
export type SpreadPropertyKind = namedTypes.SpreadProperty;
export type SpreadPropertyPatternKind = namedTypes.SpreadPropertyPattern;
export type ImportExpressionKind = namedTypes.ImportExpression;
export type ChainExpressionKind = namedTypes.ChainExpression;
export type OptionalCallExpressionKind = namedTypes.OptionalCallExpression;
export type OptionalMemberExpressionKind = namedTypes.OptionalMemberExpression;
export type StaticBlockKind = namedTypes.StaticBlock;
export type DecoratorKind = namedTypes.Decorator;
export type PrivateNameKind = namedTypes.PrivateName;
export type ClassPrivatePropertyKind = namedTypes.ClassPrivateProperty;
export type ImportAttributeKind = namedTypes.ImportAttribute;
export type RecordExpressionKind = namedTypes.RecordExpression;
export type ObjectMethodKind = namedTypes.ObjectMethod;
export type TupleExpressionKind = namedTypes.TupleExpression;
export type ModuleExpressionKind = namedTypes.ModuleExpression;
export type JSXAttributeKind = namedTypes.JSXAttribute;
export type JSXIdentifierKind = namedTypes.JSXIdentifier;
export type JSXNamespacedNameKind = namedTypes.JSXNamespacedName;
export type JSXExpressionContainerKind = namedTypes.JSXExpressionContainer;
export type JSXElementKind = namedTypes.JSXElement;
export type JSXFragmentKind = namedTypes.JSXFragment;
export type JSXMemberExpressionKind = namedTypes.JSXMemberExpression;
export type JSXSpreadAttributeKind = namedTypes.JSXSpreadAttribute;
export type JSXEmptyExpressionKind = namedTypes.JSXEmptyExpression;
export type JSXTextKind = namedTypes.JSXText;
export type JSXSpreadChildKind = namedTypes.JSXSpreadChild;
export type JSXOpeningElementKind = namedTypes.JSXOpeningElement;
export type JSXClosingElementKind = namedTypes.JSXClosingElement;
export type JSXOpeningFragmentKind = namedTypes.JSXOpeningFragment;
export type JSXClosingFragmentKind = namedTypes.JSXClosingFragment;
export type TypeParameterDeclarationKind = namedTypes.TypeParameterDeclaration;
export type TSTypeParameterDeclarationKind = namedTypes.TSTypeParameterDeclaration;
export type TypeParameterInstantiationKind = namedTypes.TypeParameterInstantiation;
export type TSTypeParameterInstantiationKind = namedTypes.TSTypeParameterInstantiation;
export type ClassImplementsKind = namedTypes.ClassImplements;
export type TSTypeKind = namedTypes.TSExpressionWithTypeArguments | namedTypes.TSTypeReference | namedTypes.TSAnyKeyword | namedTypes.TSBigIntKeyword | namedTypes.TSBooleanKeyword | namedTypes.TSNeverKeyword | namedTypes.TSNullKeyword | namedTypes.TSNumberKeyword | namedTypes.TSObjectKeyword | namedTypes.TSStringKeyword | namedTypes.TSSymbolKeyword | namedTypes.TSUndefinedKeyword | namedTypes.TSUnknownKeyword | namedTypes.TSVoidKeyword | namedTypes.TSIntrinsicKeyword | namedTypes.TSThisType | namedTypes.TSArrayType | namedTypes.TSLiteralType | namedTypes.TSUnionType | namedTypes.TSIntersectionType | namedTypes.TSConditionalType | namedTypes.TSInferType | namedTypes.TSParenthesizedType | namedTypes.TSFunctionType | namedTypes.TSConstructorType | namedTypes.TSMappedType | namedTypes.TSTupleType | namedTypes.TSNamedTupleMember | namedTypes.TSRestType | namedTypes.TSOptionalType | namedTypes.TSIndexedAccessType | namedTypes.TSTypeOperator | namedTypes.TSTypePredicate | namedTypes.TSTypeQuery | namedTypes.TSImportType | namedTypes.TSTypeLiteral;
export type TSHasOptionalTypeParameterInstantiationKind = namedTypes.TSExpressionWithTypeArguments | namedTypes.TSTypeReference | namedTypes.TSImportType;
export type TSExpressionWithTypeArgumentsKind = namedTypes.TSExpressionWithTypeArguments;
export type FlowKind = namedTypes.AnyTypeAnnotation | namedTypes.EmptyTypeAnnotation | namedTypes.MixedTypeAnnotation | namedTypes.VoidTypeAnnotation | namedTypes.SymbolTypeAnnotation | namedTypes.NumberTypeAnnotation | namedTypes.BigIntTypeAnnotation | namedTypes.NumberLiteralTypeAnnotation | namedTypes.NumericLiteralTypeAnnotation | namedTypes.BigIntLiteralTypeAnnotation | namedTypes.StringTypeAnnotation | namedTypes.StringLiteralTypeAnnotation | namedTypes.BooleanTypeAnnotation | namedTypes.BooleanLiteralTypeAnnotation | namedTypes.NullableTypeAnnotation | namedTypes.NullLiteralTypeAnnotation | namedTypes.NullTypeAnnotation | namedTypes.ThisTypeAnnotation | namedTypes.ExistsTypeAnnotation | namedTypes.ExistentialTypeParam | namedTypes.FunctionTypeAnnotation | namedTypes.ArrayTypeAnnotation | namedTypes.ObjectTypeAnnotation | namedTypes.GenericTypeAnnotation | namedTypes.MemberTypeAnnotation | namedTypes.IndexedAccessType | namedTypes.OptionalIndexedAccessType | namedTypes.UnionTypeAnnotation | namedTypes.IntersectionTypeAnnotation | namedTypes.TypeofTypeAnnotation | namedTypes.TypeParameter | namedTypes.InterfaceTypeAnnotation | namedTypes.TupleTypeAnnotation | namedTypes.InferredPredicate | namedTypes.DeclaredPredicate;
export type FlowTypeKind = namedTypes.AnyTypeAnnotation | namedTypes.EmptyTypeAnnotation | namedTypes.MixedTypeAnnotation | namedTypes.VoidTypeAnnotation | namedTypes.SymbolTypeAnnotation | namedTypes.NumberTypeAnnotation | namedTypes.BigIntTypeAnnotation | namedTypes.NumberLiteralTypeAnnotation | namedTypes.NumericLiteralTypeAnnotation | namedTypes.BigIntLiteralTypeAnnotation | namedTypes.StringTypeAnnotation | namedTypes.StringLiteralTypeAnnotation | namedTypes.BooleanTypeAnnotation | namedTypes.BooleanLiteralTypeAnnotation | namedTypes.NullableTypeAnnotation | namedTypes.NullLiteralTypeAnnotation | namedTypes.NullTypeAnnotation | namedTypes.ThisTypeAnnotation | namedTypes.ExistsTypeAnnotation | namedTypes.ExistentialTypeParam | namedTypes.FunctionTypeAnnotation | namedTypes.ArrayTypeAnnotation | namedTypes.ObjectTypeAnnotation | namedTypes.GenericTypeAnnotation | namedTypes.MemberTypeAnnotation | namedTypes.IndexedAccessType | namedTypes.OptionalIndexedAccessType | namedTypes.UnionTypeAnnotation | namedTypes.IntersectionTypeAnnotation | namedTypes.TypeofTypeAnnotation | namedTypes.TypeParameter | namedTypes.InterfaceTypeAnnotation | namedTypes.TupleTypeAnnotation;
export type AnyTypeAnnotationKind = namedTypes.AnyTypeAnnotation;
export type EmptyTypeAnnotationKind = namedTypes.EmptyTypeAnnotation;
export type MixedTypeAnnotationKind = namedTypes.MixedTypeAnnotation;
export type VoidTypeAnnotationKind = namedTypes.VoidTypeAnnotation;
export type SymbolTypeAnnotationKind = namedTypes.SymbolTypeAnnotation;
export type NumberTypeAnnotationKind = namedTypes.NumberTypeAnnotation;
export type BigIntTypeAnnotationKind = namedTypes.BigIntTypeAnnotation;
export type NumberLiteralTypeAnnotationKind = namedTypes.NumberLiteralTypeAnnotation;
export type NumericLiteralTypeAnnotationKind = namedTypes.NumericLiteralTypeAnnotation;
export type BigIntLiteralTypeAnnotationKind = namedTypes.BigIntLiteralTypeAnnotation;
export type StringTypeAnnotationKind = namedTypes.StringTypeAnnotation;
export type StringLiteralTypeAnnotationKind = namedTypes.StringLiteralTypeAnnotation;
export type BooleanTypeAnnotationKind = namedTypes.BooleanTypeAnnotation;
export type BooleanLiteralTypeAnnotationKind = namedTypes.BooleanLiteralTypeAnnotation;
export type NullableTypeAnnotationKind = namedTypes.NullableTypeAnnotation;
export type NullLiteralTypeAnnotationKind = namedTypes.NullLiteralTypeAnnotation;
export type NullTypeAnnotationKind = namedTypes.NullTypeAnnotation;
export type ThisTypeAnnotationKind = namedTypes.ThisTypeAnnotation;
export type ExistsTypeAnnotationKind = namedTypes.ExistsTypeAnnotation;
export type ExistentialTypeParamKind = namedTypes.ExistentialTypeParam;
export type FunctionTypeAnnotationKind = namedTypes.FunctionTypeAnnotation;
export type FunctionTypeParamKind = namedTypes.FunctionTypeParam;
export type ArrayTypeAnnotationKind = namedTypes.ArrayTypeAnnotation;
export type ObjectTypeAnnotationKind = namedTypes.ObjectTypeAnnotation;
export type ObjectTypePropertyKind = namedTypes.ObjectTypeProperty;
export type ObjectTypeSpreadPropertyKind = namedTypes.ObjectTypeSpreadProperty;
export type ObjectTypeIndexerKind = namedTypes.ObjectTypeIndexer;
export type ObjectTypeCallPropertyKind = namedTypes.ObjectTypeCallProperty;
export type ObjectTypeInternalSlotKind = namedTypes.ObjectTypeInternalSlot;
export type VarianceKind = namedTypes.Variance;
export type QualifiedTypeIdentifierKind = namedTypes.QualifiedTypeIdentifier;
export type GenericTypeAnnotationKind = namedTypes.GenericTypeAnnotation;
export type MemberTypeAnnotationKind = namedTypes.MemberTypeAnnotation;
export type IndexedAccessTypeKind = namedTypes.IndexedAccessType;
export type OptionalIndexedAccessTypeKind = namedTypes.OptionalIndexedAccessType;
export type UnionTypeAnnotationKind = namedTypes.UnionTypeAnnotation;
export type IntersectionTypeAnnotationKind = namedTypes.IntersectionTypeAnnotation;
export type TypeofTypeAnnotationKind = namedTypes.TypeofTypeAnnotation;
export type TypeParameterKind = namedTypes.TypeParameter;
export type InterfaceTypeAnnotationKind = namedTypes.InterfaceTypeAnnotation;
export type InterfaceExtendsKind = namedTypes.InterfaceExtends;
export type InterfaceDeclarationKind = namedTypes.InterfaceDeclaration | namedTypes.DeclareInterface | namedTypes.DeclareClass;
export type DeclareInterfaceKind = namedTypes.DeclareInterface;
export type TypeAliasKind = namedTypes.TypeAlias | namedTypes.DeclareTypeAlias;
export type DeclareTypeAliasKind = namedTypes.DeclareTypeAlias;
export type OpaqueTypeKind = namedTypes.OpaqueType | namedTypes.DeclareOpaqueType;
export type DeclareOpaqueTypeKind = namedTypes.DeclareOpaqueType;
export type TypeCastExpressionKind = namedTypes.TypeCastExpression;
export type TupleTypeAnnotationKind = namedTypes.TupleTypeAnnotation;
export type DeclareVariableKind = namedTypes.DeclareVariable;
export type DeclareFunctionKind = namedTypes.DeclareFunction;
export type FlowPredicateKind = namedTypes.InferredPredicate | namedTypes.DeclaredPredicate;
export type DeclareClassKind = namedTypes.DeclareClass;
export type DeclareModuleKind = namedTypes.DeclareModule;
export type DeclareModuleExportsKind = namedTypes.DeclareModuleExports;
export type DeclareExportDeclarationKind = namedTypes.DeclareExportDeclaration;
export type ExportBatchSpecifierKind = namedTypes.ExportBatchSpecifier;
export type DeclareExportAllDeclarationKind = namedTypes.DeclareExportAllDeclaration;
export type InferredPredicateKind = namedTypes.InferredPredicate;
export type DeclaredPredicateKind = namedTypes.DeclaredPredicate;
export type EnumDeclarationKind = namedTypes.EnumDeclaration;
export type EnumBooleanBodyKind = namedTypes.EnumBooleanBody;
export type EnumNumberBodyKind = namedTypes.EnumNumberBody;
export type EnumStringBodyKind = namedTypes.EnumStringBody;
export type EnumSymbolBodyKind = namedTypes.EnumSymbolBody;
export type EnumBooleanMemberKind = namedTypes.EnumBooleanMember;
export type EnumNumberMemberKind = namedTypes.EnumNumberMember;
export type EnumStringMemberKind = namedTypes.EnumStringMember;
export type EnumDefaultedMemberKind = namedTypes.EnumDefaultedMember;
export type ExportDeclarationKind = namedTypes.ExportDeclaration;
export type BlockKind = namedTypes.Block;
export type LineKind = namedTypes.Line;
export type NoopKind = namedTypes.Noop;
export type DoExpressionKind = namedTypes.DoExpression;
export type BindExpressionKind = namedTypes.BindExpression;
export type ParenthesizedExpressionKind = namedTypes.ParenthesizedExpression;
export type ExportNamespaceSpecifierKind = namedTypes.ExportNamespaceSpecifier;
export type ExportDefaultSpecifierKind = namedTypes.ExportDefaultSpecifier;
export type CommentBlockKind = namedTypes.CommentBlock;
export type CommentLineKind = namedTypes.CommentLine;
export type DirectiveKind = namedTypes.Directive;
export type DirectiveLiteralKind = namedTypes.DirectiveLiteral;
export type InterpreterDirectiveKind = namedTypes.InterpreterDirective;
export type StringLiteralKind = namedTypes.StringLiteral;
export type NumericLiteralKind = namedTypes.NumericLiteral;
export type BigIntLiteralKind = namedTypes.BigIntLiteral;
export type DecimalLiteralKind = namedTypes.DecimalLiteral;
export type NullLiteralKind = namedTypes.NullLiteral;
export type BooleanLiteralKind = namedTypes.BooleanLiteral;
export type RegExpLiteralKind = namedTypes.RegExpLiteral;
export type ClassMethodKind = namedTypes.ClassMethod;
export type ClassPrivateMethodKind = namedTypes.ClassPrivateMethod;
export type RestPropertyKind = namedTypes.RestProperty;
export type ForAwaitStatementKind = namedTypes.ForAwaitStatement;
export type ImportKind = namedTypes.Import;
export type V8IntrinsicIdentifierKind = namedTypes.V8IntrinsicIdentifier;
export type TopicReferenceKind = namedTypes.TopicReference;
export type TSQualifiedNameKind = namedTypes.TSQualifiedName;
export type TSTypeReferenceKind = namedTypes.TSTypeReference;
export type TSHasOptionalTypeParametersKind = namedTypes.TSFunctionType | namedTypes.TSConstructorType | namedTypes.TSDeclareFunction | namedTypes.TSDeclareMethod | namedTypes.TSMethodSignature | namedTypes.TSCallSignatureDeclaration | namedTypes.TSConstructSignatureDeclaration | namedTypes.TSTypeAliasDeclaration | namedTypes.TSInterfaceDeclaration;
export type TSHasOptionalTypeAnnotationKind = namedTypes.TSFunctionType | namedTypes.TSConstructorType | namedTypes.TSIndexSignature | namedTypes.TSPropertySignature | namedTypes.TSMethodSignature | namedTypes.TSCallSignatureDeclaration | namedTypes.TSConstructSignatureDeclaration;
export type TSAsExpressionKind = namedTypes.TSAsExpression;
export type TSNonNullExpressionKind = namedTypes.TSNonNullExpression;
export type TSAnyKeywordKind = namedTypes.TSAnyKeyword;
export type TSBigIntKeywordKind = namedTypes.TSBigIntKeyword;
export type TSBooleanKeywordKind = namedTypes.TSBooleanKeyword;
export type TSNeverKeywordKind = namedTypes.TSNeverKeyword;
export type TSNullKeywordKind = namedTypes.TSNullKeyword;
export type TSNumberKeywordKind = namedTypes.TSNumberKeyword;
export type TSObjectKeywordKind = namedTypes.TSObjectKeyword;
export type TSStringKeywordKind = namedTypes.TSStringKeyword;
export type TSSymbolKeywordKind = namedTypes.TSSymbolKeyword;
export type TSUndefinedKeywordKind = namedTypes.TSUndefinedKeyword;
export type TSUnknownKeywordKind = namedTypes.TSUnknownKeyword;
export type TSVoidKeywordKind = namedTypes.TSVoidKeyword;
export type TSIntrinsicKeywordKind = namedTypes.TSIntrinsicKeyword;
export type TSThisTypeKind = namedTypes.TSThisType;
export type TSArrayTypeKind = namedTypes.TSArrayType;
export type TSLiteralTypeKind = namedTypes.TSLiteralType;
export type TSUnionTypeKind = namedTypes.TSUnionType;
export type TSIntersectionTypeKind = namedTypes.TSIntersectionType;
export type TSConditionalTypeKind = namedTypes.TSConditionalType;
export type TSInferTypeKind = namedTypes.TSInferType;
export type TSTypeParameterKind = namedTypes.TSTypeParameter;
export type TSParenthesizedTypeKind = namedTypes.TSParenthesizedType;
export type TSFunctionTypeKind = namedTypes.TSFunctionType;
export type TSConstructorTypeKind = namedTypes.TSConstructorType;
export type TSDeclareFunctionKind = namedTypes.TSDeclareFunction;
export type TSDeclareMethodKind = namedTypes.TSDeclareMethod;
export type TSMappedTypeKind = namedTypes.TSMappedType;
export type TSTupleTypeKind = namedTypes.TSTupleType;
export type TSNamedTupleMemberKind = namedTypes.TSNamedTupleMember;
export type TSRestTypeKind = namedTypes.TSRestType;
export type TSOptionalTypeKind = namedTypes.TSOptionalType;
export type TSIndexedAccessTypeKind = namedTypes.TSIndexedAccessType;
export type TSTypeOperatorKind = namedTypes.TSTypeOperator;
export type TSIndexSignatureKind = namedTypes.TSIndexSignature;
export type TSPropertySignatureKind = namedTypes.TSPropertySignature;
export type TSMethodSignatureKind = namedTypes.TSMethodSignature;
export type TSTypePredicateKind = namedTypes.TSTypePredicate;
export type TSCallSignatureDeclarationKind = namedTypes.TSCallSignatureDeclaration;
export type TSConstructSignatureDeclarationKind = namedTypes.TSConstructSignatureDeclaration;
export type TSEnumMemberKind = namedTypes.TSEnumMember;
export type TSTypeQueryKind = namedTypes.TSTypeQuery;
export type TSImportTypeKind = namedTypes.TSImportType;
export type TSTypeLiteralKind = namedTypes.TSTypeLiteral;
export type TSTypeAssertionKind = namedTypes.TSTypeAssertion;
export type TSEnumDeclarationKind = namedTypes.TSEnumDeclaration;
export type TSTypeAliasDeclarationKind = namedTypes.TSTypeAliasDeclaration;
export type TSModuleBlockKind = namedTypes.TSModuleBlock;
export type TSModuleDeclarationKind = namedTypes.TSModuleDeclaration;
export type TSImportEqualsDeclarationKind = namedTypes.TSImportEqualsDeclaration;
export type TSExternalModuleReferenceKind = namedTypes.TSExternalModuleReference;
export type TSExportAssignmentKind = namedTypes.TSExportAssignment;
export type TSNamespaceExportDeclarationKind = namedTypes.TSNamespaceExportDeclaration;
export type TSInterfaceBodyKind = namedTypes.TSInterfaceBody;
export type TSInterfaceDeclarationKind = namedTypes.TSInterfaceDeclaration;
export type TSParameterPropertyKind = namedTypes.TSParameterProperty;ast-types-0.15.2/gen/namedTypes.ts000066400000000000000000002573611415222403600167770ustar00rootroot00000000000000/* !!! THIS FILE WAS AUTO-GENERATED BY `npm run gen` !!! */
import { Omit } from "../types";
import { Type } from "../lib/types";
import * as K from "./kinds";
export namespace namedTypes {
export interface Printable {
loc?: K.SourceLocationKind | null;
}
export interface SourceLocation {
start: K.PositionKind;
end: K.PositionKind;
source?: string | null;
}
export interface Node extends Printable {
type: string;
comments?: K.CommentKind[] | null;
}
export interface Comment extends Printable {
value: string;
leading?: boolean;
trailing?: boolean;
}
export interface Position {
line: number;
column: number;
}
export interface File extends Omit {
type: "File";
program: K.ProgramKind;
name?: string | null;
}
export interface Program extends Omit {
type: "Program";
body: K.StatementKind[];
directives?: K.DirectiveKind[];
interpreter?: K.InterpreterDirectiveKind | null;
}
export interface Statement extends Node {}
export interface Function extends Node {
id?: K.IdentifierKind | null;
params: K.PatternKind[];
body: K.BlockStatementKind;
generator?: boolean;
async?: boolean;
expression?: boolean;
defaults?: (K.ExpressionKind | null)[];
rest?: K.IdentifierKind | null;
returnType?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null;
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null;
predicate?: K.FlowPredicateKind | null;
}
export interface Expression extends Node {}
export interface Pattern extends Node {}
export interface Identifier extends Omit, Omit {
type: "Identifier";
name: string;
optional?: boolean;
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null;
}
export interface BlockStatement extends Omit {
type: "BlockStatement";
body: K.StatementKind[];
directives?: K.DirectiveKind[];
}
export interface EmptyStatement extends Omit {
type: "EmptyStatement";
}
export interface ExpressionStatement extends Omit {
type: "ExpressionStatement";
expression: K.ExpressionKind;
}
export interface IfStatement extends Omit {
type: "IfStatement";
test: K.ExpressionKind;
consequent: K.StatementKind;
alternate?: K.StatementKind | null;
}
export interface LabeledStatement extends Omit {
type: "LabeledStatement";
label: K.IdentifierKind;
body: K.StatementKind;
}
export interface BreakStatement extends Omit {
type: "BreakStatement";
label?: K.IdentifierKind | null;
}
export interface ContinueStatement extends Omit {
type: "ContinueStatement";
label?: K.IdentifierKind | null;
}
export interface WithStatement extends Omit {
type: "WithStatement";
object: K.ExpressionKind;
body: K.StatementKind;
}
export interface SwitchStatement extends Omit {
type: "SwitchStatement";
discriminant: K.ExpressionKind;
cases: K.SwitchCaseKind[];
lexical?: boolean;
}
export interface SwitchCase extends Omit {
type: "SwitchCase";
test: K.ExpressionKind | null;
consequent: K.StatementKind[];
}
export interface ReturnStatement extends Omit {
type: "ReturnStatement";
argument: K.ExpressionKind | null;
}
export interface ThrowStatement extends Omit {
type: "ThrowStatement";
argument: K.ExpressionKind;
}
export interface TryStatement extends Omit {
type: "TryStatement";
block: K.BlockStatementKind;
handler?: K.CatchClauseKind | null;
handlers?: K.CatchClauseKind[];
guardedHandlers?: K.CatchClauseKind[];
finalizer?: K.BlockStatementKind | null;
}
export interface CatchClause extends Omit {
type: "CatchClause";
param?: K.PatternKind | null;
guard?: K.ExpressionKind | null;
body: K.BlockStatementKind;
}
export interface WhileStatement extends Omit {
type: "WhileStatement";
test: K.ExpressionKind;
body: K.StatementKind;
}
export interface DoWhileStatement extends Omit {
type: "DoWhileStatement";
body: K.StatementKind;
test: K.ExpressionKind;
}
export interface ForStatement extends Omit {
type: "ForStatement";
init: K.VariableDeclarationKind | K.ExpressionKind | null;
test: K.ExpressionKind | null;
update: K.ExpressionKind | null;
body: K.StatementKind;
}
export interface Declaration extends Statement {}
export interface VariableDeclaration extends Omit {
type: "VariableDeclaration";
kind: "var" | "let" | "const";
declarations: (K.VariableDeclaratorKind | K.IdentifierKind)[];
}
export interface ForInStatement extends Omit {
type: "ForInStatement";
left: K.VariableDeclarationKind | K.ExpressionKind;
right: K.ExpressionKind;
body: K.StatementKind;
}
export interface DebuggerStatement extends Omit {
type: "DebuggerStatement";
}
export interface FunctionDeclaration extends Omit, Omit {
type: "FunctionDeclaration";
id: K.IdentifierKind | null;
}
export interface FunctionExpression extends Omit, Omit {
type: "FunctionExpression";
}
export interface VariableDeclarator extends Omit {
type: "VariableDeclarator";
id: K.PatternKind;
init?: K.ExpressionKind | null;
}
export interface ThisExpression extends Omit {
type: "ThisExpression";
}
export interface ArrayExpression extends Omit {
type: "ArrayExpression";
elements: (K.ExpressionKind | K.SpreadElementKind | K.RestElementKind | null)[];
}
export interface ObjectExpression extends Omit {
type: "ObjectExpression";
properties: (K.PropertyKind | K.ObjectMethodKind | K.ObjectPropertyKind | K.SpreadPropertyKind | K.SpreadElementKind)[];
}
export interface Property extends Omit {
type: "Property";
kind: "init" | "get" | "set";
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind;
value: K.ExpressionKind | K.PatternKind;
method?: boolean;
shorthand?: boolean;
computed?: boolean;
decorators?: K.DecoratorKind[] | null;
}
export interface Literal extends Omit {
type: "Literal";
value: string | boolean | null | number | RegExp | BigInt;
}
export interface SequenceExpression extends Omit {
type: "SequenceExpression";
expressions: K.ExpressionKind[];
}
export interface UnaryExpression extends Omit {
type: "UnaryExpression";
operator: "-" | "+" | "!" | "~" | "typeof" | "void" | "delete";
argument: K.ExpressionKind;
prefix?: boolean;
}
export interface BinaryExpression extends Omit {
type: "BinaryExpression";
operator: "==" | "!=" | "===" | "!==" | "<" | "<=" | ">" | ">=" | "<<" | ">>" | ">>>" | "+" | "-" | "*" | "/" | "%" | "&" | "|" | "^" | "in" | "instanceof" | "**";
left: K.ExpressionKind;
right: K.ExpressionKind;
}
export interface AssignmentExpression extends Omit {
type: "AssignmentExpression";
operator: "=" | "+=" | "-=" | "*=" | "/=" | "%=" | "<<=" | ">>=" | ">>>=" | "|=" | "^=" | "&=" | "**=" | "||=" | "&&=" | "??=";
left: K.PatternKind | K.MemberExpressionKind;
right: K.ExpressionKind;
}
export interface ChainElement extends Node {
optional?: boolean;
}
export interface MemberExpression extends Omit, Omit {
type: "MemberExpression";
object: K.ExpressionKind;
property: K.IdentifierKind | K.ExpressionKind;
computed?: boolean;
}
export interface UpdateExpression extends Omit {
type: "UpdateExpression";
operator: "++" | "--";
argument: K.ExpressionKind;
prefix: boolean;
}
export interface LogicalExpression extends Omit {
type: "LogicalExpression";
operator: "||" | "&&" | "??";
left: K.ExpressionKind;
right: K.ExpressionKind;
}
export interface ConditionalExpression extends Omit {
type: "ConditionalExpression";
test: K.ExpressionKind;
consequent: K.ExpressionKind;
alternate: K.ExpressionKind;
}
export interface NewExpression extends Omit {
type: "NewExpression";
callee: K.ExpressionKind;
arguments: (K.ExpressionKind | K.SpreadElementKind)[];
typeArguments?: null | K.TypeParameterInstantiationKind;
}
export interface CallExpression extends Omit, Omit {
type: "CallExpression";
callee: K.ExpressionKind;
arguments: (K.ExpressionKind | K.SpreadElementKind)[];
typeArguments?: null | K.TypeParameterInstantiationKind;
}
export interface RestElement extends Omit {
type: "RestElement";
argument: K.PatternKind;
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null;
}
export interface TypeAnnotation extends Omit {
type: "TypeAnnotation";
typeAnnotation: K.FlowTypeKind;
}
export interface TSTypeAnnotation extends Omit {
type: "TSTypeAnnotation";
typeAnnotation: K.TSTypeKind | K.TSTypeAnnotationKind;
}
export interface SpreadElementPattern extends Omit {
type: "SpreadElementPattern";
argument: K.PatternKind;
}
export interface ArrowFunctionExpression extends Omit, Omit {
type: "ArrowFunctionExpression";
id?: null;
body: K.BlockStatementKind | K.ExpressionKind;
generator?: false;
}
export interface ForOfStatement extends Omit {
type: "ForOfStatement";
left: K.VariableDeclarationKind | K.PatternKind;
right: K.ExpressionKind;
body: K.StatementKind;
await?: boolean;
}
export interface YieldExpression extends Omit {
type: "YieldExpression";
argument: K.ExpressionKind | null;
delegate?: boolean;
}
export interface GeneratorExpression extends Omit {
type: "GeneratorExpression";
body: K.ExpressionKind;
blocks: K.ComprehensionBlockKind[];
filter: K.ExpressionKind | null;
}
export interface ComprehensionBlock extends Omit {
type: "ComprehensionBlock";
left: K.PatternKind;
right: K.ExpressionKind;
each: boolean;
}
export interface ComprehensionExpression extends Omit {
type: "ComprehensionExpression";
body: K.ExpressionKind;
blocks: K.ComprehensionBlockKind[];
filter: K.ExpressionKind | null;
}
export interface ObjectProperty extends Omit {
shorthand?: boolean;
type: "ObjectProperty";
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind;
value: K.ExpressionKind | K.PatternKind;
accessibility?: K.LiteralKind | null;
computed?: boolean;
}
export interface PropertyPattern extends Omit {
type: "PropertyPattern";
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind;
pattern: K.PatternKind;
computed?: boolean;
}
export interface ObjectPattern extends Omit {
type: "ObjectPattern";
properties: (K.PropertyKind | K.PropertyPatternKind | K.SpreadPropertyPatternKind | K.SpreadPropertyKind | K.ObjectPropertyKind | K.RestPropertyKind)[];
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null;
decorators?: K.DecoratorKind[] | null;
}
export interface ArrayPattern extends Omit {
type: "ArrayPattern";
elements: (K.PatternKind | K.SpreadElementKind | null)[];
}
export interface SpreadElement extends Omit {
type: "SpreadElement";
argument: K.ExpressionKind;
}
export interface AssignmentPattern extends Omit {
type: "AssignmentPattern";
left: K.PatternKind;
right: K.ExpressionKind;
}
export interface MethodDefinition extends Omit {
type: "MethodDefinition";
kind: "constructor" | "method" | "get" | "set";
key: K.ExpressionKind;
value: K.FunctionKind;
computed?: boolean;
static?: boolean;
decorators?: K.DecoratorKind[] | null;
}
export interface ClassPropertyDefinition extends Omit {
type: "ClassPropertyDefinition";
definition: K.MethodDefinitionKind | K.VariableDeclaratorKind | K.ClassPropertyDefinitionKind | K.ClassPropertyKind;
}
export interface ClassProperty extends Omit {
type: "ClassProperty";
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind;
computed?: boolean;
value: K.ExpressionKind | null;
static?: boolean;
typeAnnotation?: K.TypeAnnotationKind | K.TSTypeAnnotationKind | null;
variance?: K.VarianceKind | "plus" | "minus" | null;
access?: "public" | "private" | "protected" | undefined;
}
export interface ClassBody extends Omit {
type: "ClassBody";
body: (K.MethodDefinitionKind | K.VariableDeclaratorKind | K.ClassPropertyDefinitionKind | K.ClassPropertyKind | K.ClassPrivatePropertyKind | K.ClassMethodKind | K.ClassPrivateMethodKind | K.TSDeclareMethodKind | K.TSCallSignatureDeclarationKind | K.TSConstructSignatureDeclarationKind | K.TSIndexSignatureKind | K.TSMethodSignatureKind | K.TSPropertySignatureKind)[];
}
export interface ClassDeclaration extends Omit {
type: "ClassDeclaration";
id: K.IdentifierKind | null;
body: K.ClassBodyKind;
superClass?: K.ExpressionKind | null;
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null;
superTypeParameters?: K.TypeParameterInstantiationKind | K.TSTypeParameterInstantiationKind | null;
implements?: K.ClassImplementsKind[] | K.TSExpressionWithTypeArgumentsKind[];
}
export interface ClassExpression extends Omit {
type: "ClassExpression";
id?: K.IdentifierKind | null;
body: K.ClassBodyKind;
superClass?: K.ExpressionKind | null;
typeParameters?: K.TypeParameterDeclarationKind | K.TSTypeParameterDeclarationKind | null;
superTypeParameters?: K.TypeParameterInstantiationKind | K.TSTypeParameterInstantiationKind | null;
implements?: K.ClassImplementsKind[] | K.TSExpressionWithTypeArgumentsKind[];
}
export interface Super extends Omit {
type: "Super";
}
export interface Specifier extends Node {}
export interface ModuleSpecifier extends Specifier {
local?: K.IdentifierKind | null;
id?: K.IdentifierKind | null;
name?: K.IdentifierKind | null;
}
export interface ImportSpecifier extends Omit {
type: "ImportSpecifier";
imported: K.IdentifierKind;
}
export interface ImportDefaultSpecifier extends Omit {
type: "ImportDefaultSpecifier";
}
export interface ImportNamespaceSpecifier extends Omit {
type: "ImportNamespaceSpecifier";
}
export interface ImportDeclaration extends Omit {
type: "ImportDeclaration";
specifiers?: (K.ImportSpecifierKind | K.ImportNamespaceSpecifierKind | K.ImportDefaultSpecifierKind)[];
source: K.LiteralKind;
importKind?: "value" | "type" | "typeof";
assertions?: K.ImportAttributeKind[];
}
export interface ExportNamedDeclaration extends Omit {
type: "ExportNamedDeclaration";
declaration: K.DeclarationKind | null;
specifiers?: K.ExportSpecifierKind[];
source?: K.LiteralKind | null;
assertions?: K.ImportAttributeKind[];
}
export interface ExportSpecifier extends Omit {
type: "ExportSpecifier";
exported: K.IdentifierKind;
}
export interface ExportDefaultDeclaration extends Omit {
type: "ExportDefaultDeclaration";
declaration: K.DeclarationKind | K.ExpressionKind;
}
export interface ExportAllDeclaration extends Omit {
type: "ExportAllDeclaration";
source: K.LiteralKind;
exported: K.IdentifierKind | null;
assertions?: K.ImportAttributeKind[];
}
export interface TaggedTemplateExpression extends Omit {
type: "TaggedTemplateExpression";
tag: K.ExpressionKind;
quasi: K.TemplateLiteralKind;
}
export interface TemplateLiteral extends Omit {
type: "TemplateLiteral";
quasis: K.TemplateElementKind[];
expressions: K.ExpressionKind[] | K.TSTypeKind[];
}
export interface TemplateElement extends Omit {
type: "TemplateElement";
value: {
cooked: string | null,
raw: string
};
tail: boolean;
}
export interface MetaProperty extends Omit {
type: "MetaProperty";
meta: K.IdentifierKind;
property: K.IdentifierKind;
}
export interface AwaitExpression extends Omit {
type: "AwaitExpression";
argument: K.ExpressionKind | null;
all?: boolean;
}
export interface SpreadProperty extends Omit {
type: "SpreadProperty";
argument: K.ExpressionKind;
}
export interface SpreadPropertyPattern extends Omit {
type: "SpreadPropertyPattern";
argument: K.PatternKind;
}
export interface ImportExpression extends Omit {
type: "ImportExpression";
source: K.ExpressionKind;
}
export interface ChainExpression extends Omit {
type: "ChainExpression";
expression: K.ChainElementKind;
}
export interface OptionalCallExpression extends Omit {
type: "OptionalCallExpression";
optional?: boolean;
}
export interface OptionalMemberExpression extends Omit {
type: "OptionalMemberExpression";
optional?: boolean;
}
export interface StaticBlock extends Omit {
type: "StaticBlock";
body: K.StatementKind[];
}
export interface Decorator extends Omit {
type: "Decorator";
expression: K.ExpressionKind;
}
export interface PrivateName extends Omit, Omit {
type: "PrivateName";
id: K.IdentifierKind;
}
export interface ClassPrivateProperty extends Omit {
type: "ClassPrivateProperty";
key: K.PrivateNameKind;
value?: K.ExpressionKind | null;
}
export interface ImportAttribute extends Omit {
type: "ImportAttribute";
key: K.IdentifierKind | K.LiteralKind;
value: K.ExpressionKind;
}
export interface RecordExpression extends Omit {
type: "RecordExpression";
properties: (K.ObjectPropertyKind | K.ObjectMethodKind | K.SpreadElementKind)[];
}
export interface ObjectMethod extends Omit, Omit {
type: "ObjectMethod";
kind: "method" | "get" | "set";
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind;
params: K.PatternKind[];
body: K.BlockStatementKind;
computed?: boolean;
generator?: boolean;
async?: boolean;
accessibility?: K.LiteralKind | null;
decorators?: K.DecoratorKind[] | null;
}
export interface TupleExpression extends Omit {
type: "TupleExpression";
elements: (K.ExpressionKind | K.SpreadElementKind | null)[];
}
export interface ModuleExpression extends Omit {
type: "ModuleExpression";
body: K.ProgramKind;
}
export interface JSXAttribute extends Omit {
type: "JSXAttribute";
name: K.JSXIdentifierKind | K.JSXNamespacedNameKind;
value?: K.LiteralKind | K.JSXExpressionContainerKind | K.JSXElementKind | K.JSXFragmentKind | null;
}
export interface JSXIdentifier extends Omit {
type: "JSXIdentifier";
name: string;
}
export interface JSXNamespacedName extends Omit {
type: "JSXNamespacedName";
namespace: K.JSXIdentifierKind;
name: K.JSXIdentifierKind;
}
export interface JSXExpressionContainer extends Omit {
type: "JSXExpressionContainer";
expression: K.ExpressionKind | K.JSXEmptyExpressionKind;
}
export interface JSXElement extends Omit {
type: "JSXElement";
openingElement: K.JSXOpeningElementKind;
closingElement?: K.JSXClosingElementKind | null;
children?: (K.JSXTextKind | K.JSXExpressionContainerKind | K.JSXSpreadChildKind | K.JSXElementKind | K.JSXFragmentKind | K.LiteralKind)[];
name?: K.JSXIdentifierKind | K.JSXNamespacedNameKind | K.JSXMemberExpressionKind;
selfClosing?: boolean;
attributes?: (K.JSXAttributeKind | K.JSXSpreadAttributeKind)[];
}
export interface JSXFragment extends Omit {
type: "JSXFragment";
openingFragment: K.JSXOpeningFragmentKind;
closingFragment: K.JSXClosingFragmentKind;
children?: (K.JSXTextKind | K.JSXExpressionContainerKind | K.JSXSpreadChildKind | K.JSXElementKind | K.JSXFragmentKind | K.LiteralKind)[];
}
export interface JSXMemberExpression extends Omit {
type: "JSXMemberExpression";
object: K.JSXIdentifierKind | K.JSXMemberExpressionKind;
property: K.JSXIdentifierKind;
computed?: boolean;
}
export interface JSXSpreadAttribute extends Omit {
type: "JSXSpreadAttribute";
argument: K.ExpressionKind;
}
export interface JSXEmptyExpression extends Omit {
type: "JSXEmptyExpression";
}
export interface JSXText extends Omit {
type: "JSXText";
value: string;
raw?: string;
}
export interface JSXSpreadChild extends Omit {
type: "JSXSpreadChild";
expression: K.ExpressionKind;
}
export interface JSXOpeningElement extends Omit {
type: "JSXOpeningElement";
name: K.JSXIdentifierKind | K.JSXNamespacedNameKind | K.JSXMemberExpressionKind;
attributes?: (K.JSXAttributeKind | K.JSXSpreadAttributeKind)[];
selfClosing?: boolean;
}
export interface JSXClosingElement extends Omit {
type: "JSXClosingElement";
name: K.JSXIdentifierKind | K.JSXNamespacedNameKind | K.JSXMemberExpressionKind;
}
export interface JSXOpeningFragment extends Omit {
type: "JSXOpeningFragment";
}
export interface JSXClosingFragment extends Omit {
type: "JSXClosingFragment";
}
export interface TypeParameterDeclaration extends Omit {
type: "TypeParameterDeclaration";
params: K.TypeParameterKind[];
}
export interface TSTypeParameterDeclaration extends Omit {
type: "TSTypeParameterDeclaration";
params: K.TSTypeParameterKind[];
}
export interface TypeParameterInstantiation extends Omit {
type: "TypeParameterInstantiation";
params: K.FlowTypeKind[];
}
export interface TSTypeParameterInstantiation extends Omit {
type: "TSTypeParameterInstantiation";
params: K.TSTypeKind[];
}
export interface ClassImplements extends Omit {
type: "ClassImplements";
id: K.IdentifierKind;
superClass?: K.ExpressionKind | null;
typeParameters?: K.TypeParameterInstantiationKind | null;
}
export interface TSType extends Node {}
export interface TSHasOptionalTypeParameterInstantiation {
typeParameters?: K.TSTypeParameterInstantiationKind | null;
}
export interface TSExpressionWithTypeArguments extends Omit, TSHasOptionalTypeParameterInstantiation {
type: "TSExpressionWithTypeArguments";
expression: K.IdentifierKind | K.TSQualifiedNameKind;
}
export interface Flow extends Node {}
export interface FlowType extends Flow {}
export interface AnyTypeAnnotation extends Omit {
type: "AnyTypeAnnotation";
}
export interface EmptyTypeAnnotation extends Omit {
type: "EmptyTypeAnnotation";
}
export interface MixedTypeAnnotation extends Omit {
type: "MixedTypeAnnotation";
}
export interface VoidTypeAnnotation extends Omit {
type: "VoidTypeAnnotation";
}
export interface SymbolTypeAnnotation extends Omit {
type: "SymbolTypeAnnotation";
}
export interface NumberTypeAnnotation extends Omit {
type: "NumberTypeAnnotation";
}
export interface BigIntTypeAnnotation extends Omit {
type: "BigIntTypeAnnotation";
}
export interface NumberLiteralTypeAnnotation extends Omit {
type: "NumberLiteralTypeAnnotation";
value: number;
raw: string;
}
export interface NumericLiteralTypeAnnotation extends Omit {
type: "NumericLiteralTypeAnnotation";
value: number;
raw: string;
}
export interface BigIntLiteralTypeAnnotation extends Omit {
type: "BigIntLiteralTypeAnnotation";
value: null;
raw: string;
}
export interface StringTypeAnnotation extends Omit {
type: "StringTypeAnnotation";
}
export interface StringLiteralTypeAnnotation extends Omit {
type: "StringLiteralTypeAnnotation";
value: string;
raw: string;
}
export interface BooleanTypeAnnotation extends Omit {
type: "BooleanTypeAnnotation";
}
export interface BooleanLiteralTypeAnnotation extends Omit {
type: "BooleanLiteralTypeAnnotation";
value: boolean;
raw: string;
}
export interface NullableTypeAnnotation extends Omit {
type: "NullableTypeAnnotation";
typeAnnotation: K.FlowTypeKind;
}
export interface NullLiteralTypeAnnotation extends Omit {
type: "NullLiteralTypeAnnotation";
}
export interface NullTypeAnnotation extends Omit {
type: "NullTypeAnnotation";
}
export interface ThisTypeAnnotation extends Omit {
type: "ThisTypeAnnotation";
}
export interface ExistsTypeAnnotation extends Omit {
type: "ExistsTypeAnnotation";
}
export interface ExistentialTypeParam extends Omit {
type: "ExistentialTypeParam";
}
export interface FunctionTypeAnnotation extends Omit {
type: "FunctionTypeAnnotation";
params: K.FunctionTypeParamKind[];
returnType: K.FlowTypeKind;
rest: K.FunctionTypeParamKind | null;
typeParameters: K.TypeParameterDeclarationKind | null;
}
export interface FunctionTypeParam extends Omit {
type: "FunctionTypeParam";
name: K.IdentifierKind | null;
typeAnnotation: K.FlowTypeKind;
optional: boolean;
}
export interface ArrayTypeAnnotation extends Omit {
type: "ArrayTypeAnnotation";
elementType: K.FlowTypeKind;
}
export interface ObjectTypeAnnotation extends Omit {
type: "ObjectTypeAnnotation";
properties: (K.ObjectTypePropertyKind | K.ObjectTypeSpreadPropertyKind)[];
indexers?: K.ObjectTypeIndexerKind[];
callProperties?: K.ObjectTypeCallPropertyKind[];
inexact?: boolean | undefined;
exact?: boolean;
internalSlots?: K.ObjectTypeInternalSlotKind[];
}
export interface ObjectTypeProperty extends Omit {
type: "ObjectTypeProperty";
key: K.LiteralKind | K.IdentifierKind;
value: K.FlowTypeKind;
optional: boolean;
variance?: K.VarianceKind | "plus" | "minus" | null;
}
export interface ObjectTypeSpreadProperty extends Omit {
type: "ObjectTypeSpreadProperty";
argument: K.FlowTypeKind;
}
export interface ObjectTypeIndexer extends Omit {
type: "ObjectTypeIndexer";
id: K.IdentifierKind;
key: K.FlowTypeKind;
value: K.FlowTypeKind;
variance?: K.VarianceKind | "plus" | "minus" | null;
static?: boolean;
}
export interface ObjectTypeCallProperty extends Omit {
type: "ObjectTypeCallProperty";
value: K.FunctionTypeAnnotationKind;
static?: boolean;
}
export interface ObjectTypeInternalSlot extends Omit {
type: "ObjectTypeInternalSlot";
id: K.IdentifierKind;
value: K.FlowTypeKind;
optional: boolean;
static: boolean;
method: boolean;
}
export interface Variance extends Omit {
type: "Variance";
kind: "plus" | "minus";
}
export interface QualifiedTypeIdentifier extends Omit {
type: "QualifiedTypeIdentifier";
qualification: K.IdentifierKind | K.QualifiedTypeIdentifierKind;
id: K.IdentifierKind;
}
export interface GenericTypeAnnotation extends Omit {
type: "GenericTypeAnnotation";
id: K.IdentifierKind | K.QualifiedTypeIdentifierKind;
typeParameters: K.TypeParameterInstantiationKind | null;
}
export interface MemberTypeAnnotation extends Omit {
type: "MemberTypeAnnotation";
object: K.IdentifierKind;
property: K.MemberTypeAnnotationKind | K.GenericTypeAnnotationKind;
}
export interface IndexedAccessType extends Omit {
type: "IndexedAccessType";
objectType: K.FlowTypeKind;
indexType: K.FlowTypeKind;
}
export interface OptionalIndexedAccessType extends Omit {
type: "OptionalIndexedAccessType";
objectType: K.FlowTypeKind;
indexType: K.FlowTypeKind;
optional: boolean;
}
export interface UnionTypeAnnotation extends Omit {
type: "UnionTypeAnnotation";
types: K.FlowTypeKind[];
}
export interface IntersectionTypeAnnotation extends Omit {
type: "IntersectionTypeAnnotation";
types: K.FlowTypeKind[];
}
export interface TypeofTypeAnnotation extends Omit {
type: "TypeofTypeAnnotation";
argument: K.FlowTypeKind;
}
export interface TypeParameter extends Omit {
type: "TypeParameter";
name: string;
variance?: K.VarianceKind | "plus" | "minus" | null;
bound?: K.TypeAnnotationKind | null;
default?: K.FlowTypeKind | null;
}
export interface InterfaceTypeAnnotation extends Omit {
type: "InterfaceTypeAnnotation";
body: K.ObjectTypeAnnotationKind;
extends?: K.InterfaceExtendsKind[] | null;
}
export interface InterfaceExtends extends Omit {
type: "InterfaceExtends";
id: K.IdentifierKind;
typeParameters?: K.TypeParameterInstantiationKind | null;
}
export interface InterfaceDeclaration extends Omit {
type: "InterfaceDeclaration";
id: K.IdentifierKind;
typeParameters?: K.TypeParameterDeclarationKind | null;
body: K.ObjectTypeAnnotationKind;
extends: K.InterfaceExtendsKind[];
}
export interface DeclareInterface extends Omit {
type: "DeclareInterface";
}
export interface TypeAlias extends Omit {
type: "TypeAlias";
id: K.IdentifierKind;
typeParameters: K.TypeParameterDeclarationKind | null;
right: K.FlowTypeKind;
}
export interface DeclareTypeAlias extends Omit {
type: "DeclareTypeAlias";
}
export interface OpaqueType extends Omit {
type: "OpaqueType";
id: K.IdentifierKind;
typeParameters: K.TypeParameterDeclarationKind | null;
impltype: K.FlowTypeKind;
supertype: K.FlowTypeKind | null;
}
export interface DeclareOpaqueType extends Omit {
type: "DeclareOpaqueType";
impltype: K.FlowTypeKind | null;
}
export interface TypeCastExpression extends Omit {
type: "TypeCastExpression";
expression: K.ExpressionKind;
typeAnnotation: K.TypeAnnotationKind;
}
export interface TupleTypeAnnotation extends Omit {
type: "TupleTypeAnnotation";
types: K.FlowTypeKind[];
}
export interface DeclareVariable extends Omit {
type: "DeclareVariable";
id: K.IdentifierKind;
}
export interface DeclareFunction extends Omit {
type: "DeclareFunction";
id: K.IdentifierKind;
predicate?: K.FlowPredicateKind | null;
}
export interface FlowPredicate extends Flow {}
export interface DeclareClass extends Omit {
type: "DeclareClass";
}
export interface DeclareModule extends Omit {
type: "DeclareModule";
id: K.IdentifierKind | K.LiteralKind;
body: K.BlockStatementKind;
}
export interface DeclareModuleExports extends Omit {
type: "DeclareModuleExports";
typeAnnotation: K.TypeAnnotationKind;
}
export interface DeclareExportDeclaration extends Omit {
type: "DeclareExportDeclaration";
default: boolean;
declaration: K.DeclareVariableKind | K.DeclareFunctionKind | K.DeclareClassKind | K.FlowTypeKind | K.TypeAliasKind | K.DeclareOpaqueTypeKind | K.InterfaceDeclarationKind | null;
specifiers?: (K.ExportSpecifierKind | K.ExportBatchSpecifierKind)[];
source?: K.LiteralKind | null;
}
export interface ExportBatchSpecifier extends Omit {
type: "ExportBatchSpecifier";
}
export interface DeclareExportAllDeclaration extends Omit {
type: "DeclareExportAllDeclaration";
source?: K.LiteralKind | null;
}
export interface InferredPredicate extends Omit {
type: "InferredPredicate";
}
export interface DeclaredPredicate extends Omit {
type: "DeclaredPredicate";
value: K.ExpressionKind;
}
export interface EnumDeclaration extends Omit {
type: "EnumDeclaration";
id: K.IdentifierKind;
body: K.EnumBooleanBodyKind | K.EnumNumberBodyKind | K.EnumStringBodyKind | K.EnumSymbolBodyKind;
}
export interface EnumBooleanBody {
type: "EnumBooleanBody";
members: K.EnumBooleanMemberKind[];
explicitType: boolean;
}
export interface EnumNumberBody {
type: "EnumNumberBody";
members: K.EnumNumberMemberKind[];
explicitType: boolean;
}
export interface EnumStringBody {
type: "EnumStringBody";
members: K.EnumStringMemberKind[] | K.EnumDefaultedMemberKind[];
explicitType: boolean;
}
export interface EnumSymbolBody {
type: "EnumSymbolBody";
members: K.EnumDefaultedMemberKind[];
}
export interface EnumBooleanMember {
type: "EnumBooleanMember";
id: K.IdentifierKind;
init: K.LiteralKind | boolean;
}
export interface EnumNumberMember {
type: "EnumNumberMember";
id: K.IdentifierKind;
init: K.LiteralKind;
}
export interface EnumStringMember {
type: "EnumStringMember";
id: K.IdentifierKind;
init: K.LiteralKind;
}
export interface EnumDefaultedMember {
type: "EnumDefaultedMember";
id: K.IdentifierKind;
}
export interface ExportDeclaration extends Omit {
type: "ExportDeclaration";
default: boolean;
declaration: K.DeclarationKind | K.ExpressionKind | null;
specifiers?: (K.ExportSpecifierKind | K.ExportBatchSpecifierKind)[];
source?: K.LiteralKind | null;
}
export interface Block extends Comment {
type: "Block";
}
export interface Line extends Comment {
type: "Line";
}
export interface Noop extends Omit {
type: "Noop";
}
export interface DoExpression extends Omit {
type: "DoExpression";
body: K.StatementKind[];
}
export interface BindExpression extends Omit {
type: "BindExpression";
object: K.ExpressionKind | null;
callee: K.ExpressionKind;
}
export interface ParenthesizedExpression extends Omit {
type: "ParenthesizedExpression";
expression: K.ExpressionKind;
}
export interface ExportNamespaceSpecifier extends Omit {
type: "ExportNamespaceSpecifier";
exported: K.IdentifierKind;
}
export interface ExportDefaultSpecifier extends Omit {
type: "ExportDefaultSpecifier";
exported: K.IdentifierKind;
}
export interface CommentBlock extends Comment {
type: "CommentBlock";
}
export interface CommentLine extends Comment {
type: "CommentLine";
}
export interface Directive extends Omit {
type: "Directive";
value: K.DirectiveLiteralKind;
}
export interface DirectiveLiteral extends Omit, Omit {
type: "DirectiveLiteral";
value?: string;
}
export interface InterpreterDirective extends Omit {
type: "InterpreterDirective";
value: string;
}
export interface StringLiteral extends Omit {
type: "StringLiteral";
value: string;
extra?: {
rawValue: string,
raw: string
};
}
export interface NumericLiteral extends Omit {
type: "NumericLiteral";
value: number;
raw?: string | null;
extra?: {
rawValue: number,
raw: string
};
}
export interface BigIntLiteral extends Omit {
type: "BigIntLiteral";
value: string | number;
extra?: {
rawValue: string,
raw: string
};
}
export interface DecimalLiteral extends Omit {
type: "DecimalLiteral";
value: string;
extra?: {
rawValue: string,
raw: string
};
}
export interface NullLiteral extends Omit {
type: "NullLiteral";
value?: null;
}
export interface BooleanLiteral extends Omit {
type: "BooleanLiteral";
value: boolean;
}
export interface RegExpLiteral extends Omit {
type: "RegExpLiteral";
pattern: string;
flags: string;
value?: RegExp;
extra?: {
rawValue: RegExp | undefined,
raw: string
};
regex?: {
pattern: string,
flags: string
};
}
export interface ClassMethod extends Omit, Omit {
type: "ClassMethod";
key: K.LiteralKind | K.IdentifierKind | K.ExpressionKind;
kind?: "get" | "set" | "method" | "constructor";
body: K.BlockStatementKind;
computed?: boolean;
static?: boolean | null;
abstract?: boolean | null;
access?: "public" | "private" | "protected" | null;
accessibility?: "public" | "private" | "protected" | null;
decorators?: K.DecoratorKind[] | null;
optional?: boolean | null;
}
export interface ClassPrivateMethod extends Omit, Omit {
type: "ClassPrivateMethod";
key: K.PrivateNameKind;
kind?: "get" | "set" | "method" | "constructor";
body: K.BlockStatementKind;
computed?: boolean;
static?: boolean | null;
abstract?: boolean | null;
access?: "public" | "private" | "protected" | null;
accessibility?: "public" | "private" | "protected" | null;
decorators?: K.DecoratorKind[] | null;
optional?: boolean | null;
}
export interface RestProperty extends Omit {
type: "RestProperty";
argument: K.ExpressionKind;
}
export interface ForAwaitStatement extends Omit {
type: "ForAwaitStatement";
left: K.VariableDeclarationKind | K.ExpressionKind;
right: K.ExpressionKind;
body: K.StatementKind;
}
export interface Import extends Omit {
type: "Import";
}
export interface V8IntrinsicIdentifier extends Omit {
type: "V8IntrinsicIdentifier";
name: string;
}
export interface TopicReference extends Omit {
type: "TopicReference";
}
export interface TSQualifiedName extends Omit {
type: "TSQualifiedName";
left: K.IdentifierKind | K.TSQualifiedNameKind;
right: K.IdentifierKind | K.TSQualifiedNameKind;
}
export interface TSTypeReference extends Omit, TSHasOptionalTypeParameterInstantiation {
type: "TSTypeReference";
typeName: K.IdentifierKind | K.TSQualifiedNameKind;
}
export interface TSHasOptionalTypeParameters {
typeParameters?: K.TSTypeParameterDeclarationKind | null | undefined;
}
export interface TSHasOptionalTypeAnnotation {
typeAnnotation?: K.TSTypeAnnotationKind | null;
}
export interface TSAsExpression extends Omit, Omit {
type: "TSAsExpression";
expression: K.ExpressionKind;
typeAnnotation: K.TSTypeKind;
extra?: {
parenthesized: boolean
} | null;
}
export interface TSNonNullExpression extends Omit, Omit {
type: "TSNonNullExpression";
expression: K.ExpressionKind;
}
export interface TSAnyKeyword extends Omit {
type: "TSAnyKeyword";
}
export interface TSBigIntKeyword extends Omit {
type: "TSBigIntKeyword";
}
export interface TSBooleanKeyword extends Omit {
type: "TSBooleanKeyword";
}
export interface TSNeverKeyword extends Omit {
type: "TSNeverKeyword";
}
export interface TSNullKeyword extends Omit {
type: "TSNullKeyword";
}
export interface TSNumberKeyword extends Omit {
type: "TSNumberKeyword";
}
export interface TSObjectKeyword extends Omit {
type: "TSObjectKeyword";
}
export interface TSStringKeyword extends Omit {
type: "TSStringKeyword";
}
export interface TSSymbolKeyword extends Omit {
type: "TSSymbolKeyword";
}
export interface TSUndefinedKeyword extends Omit {
type: "TSUndefinedKeyword";
}
export interface TSUnknownKeyword extends Omit {
type: "TSUnknownKeyword";
}
export interface TSVoidKeyword extends Omit {
type: "TSVoidKeyword";
}
export interface TSIntrinsicKeyword extends Omit {
type: "TSIntrinsicKeyword";
}
export interface TSThisType extends Omit {
type: "TSThisType";
}
export interface TSArrayType extends Omit {
type: "TSArrayType";
elementType: K.TSTypeKind;
}
export interface TSLiteralType extends Omit {
type: "TSLiteralType";
literal: K.NumericLiteralKind | K.StringLiteralKind | K.BooleanLiteralKind | K.TemplateLiteralKind | K.UnaryExpressionKind;
}
export interface TSUnionType extends Omit {
type: "TSUnionType";
types: K.TSTypeKind[];
}
export interface TSIntersectionType extends Omit {
type: "TSIntersectionType";
types: K.TSTypeKind[];
}
export interface TSConditionalType extends Omit {
type: "TSConditionalType";
checkType: K.TSTypeKind;
extendsType: K.TSTypeKind;
trueType: K.TSTypeKind;
falseType: K.TSTypeKind;
}
export interface TSInferType extends Omit {
type: "TSInferType";
typeParameter: K.TSTypeParameterKind;
}
export interface TSTypeParameter extends Omit {
type: "TSTypeParameter";
name: string;
constraint?: K.TSTypeKind | undefined;
default?: K.TSTypeKind | undefined;
}
export interface TSParenthesizedType extends Omit {
type: "TSParenthesizedType";
typeAnnotation: K.TSTypeKind;
}
export interface TSFunctionType extends Omit, TSHasOptionalTypeParameters, TSHasOptionalTypeAnnotation {
type: "TSFunctionType";
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[];
}
export interface TSConstructorType extends Omit, TSHasOptionalTypeParameters, TSHasOptionalTypeAnnotation {
type: "TSConstructorType";
parameters: (K.IdentifierKind | K.RestElementKind | K.ArrayPatternKind | K.ObjectPatternKind)[];
}
export interface TSDeclareFunction extends Omit, TSHasOptionalTypeParameters {
type: "TSDeclareFunction";
declare?: boolean;
async?: boolean;
generator?: boolean;
id?: K.IdentifierKind | null;
params: K.PatternKind[];
returnType?: K.TSTypeAnnotationKind | K.NoopKind | null;
}
export interface TSDeclareMethod extends Omit