js-ast-parser
Version:
把javascript代码字符串解析为AST对象
20 lines (19 loc) • 797 B
TypeScript
import { AstNode } from "../AstNode";
import { IdentifierLiteralExpression } from "../expression/IdentifierLiteralExpression";
import { StringLiteralExpression } from "../expression/StringLiteralExpression";
import { Statement } from "./Statement";
import { VariableDeclarationStatement } from "./VariableDeclarationStatement";
export declare type ExportSpecifier = {
exported: IdentifierLiteralExpression;
local: IdentifierLiteralExpression;
};
export declare class ExportDeclarationStatement extends Statement {
type: string;
code: any;
declaration: VariableDeclarationStatement;
exported: AstNode;
local: IdentifierLiteralExpression;
specifiers: Array<ExportSpecifier>;
from: StringLiteralExpression;
constructor(currentToken: any);
}