@types/estree
Advanced tools
Comparing version 1.0.1 to 1.0.2
@@ -66,3 +66,3 @@ // Type definitions for non-npm package estree 1.0 | ||
export interface Comment extends BaseNodeWithoutComments { | ||
type: 'Line' | 'Block'; | ||
type: "Line" | "Block"; | ||
value: string; | ||
@@ -85,4 +85,4 @@ } | ||
export interface Program extends BaseNode { | ||
type: 'Program'; | ||
sourceType: 'script' | 'module'; | ||
type: "Program"; | ||
sourceType: "script" | "module"; | ||
body: Array<Directive | Statement | ModuleDeclaration>; | ||
@@ -93,3 +93,3 @@ comments?: Comment[] | undefined; | ||
export interface Directive extends BaseNode { | ||
type: 'ExpressionStatement'; | ||
type: "ExpressionStatement"; | ||
expression: Literal; | ||
@@ -136,7 +136,7 @@ directive: string; | ||
export interface EmptyStatement extends BaseStatement { | ||
type: 'EmptyStatement'; | ||
type: "EmptyStatement"; | ||
} | ||
export interface BlockStatement extends BaseStatement { | ||
type: 'BlockStatement'; | ||
type: "BlockStatement"; | ||
body: Statement[]; | ||
@@ -146,8 +146,8 @@ innerComments?: Comment[] | undefined; | ||
export interface StaticBlock extends Omit<BlockStatement, 'type'> { | ||
type: 'StaticBlock'; | ||
export interface StaticBlock extends Omit<BlockStatement, "type"> { | ||
type: "StaticBlock"; | ||
} | ||
export interface ExpressionStatement extends BaseStatement { | ||
type: 'ExpressionStatement'; | ||
type: "ExpressionStatement"; | ||
expression: Expression; | ||
@@ -157,3 +157,3 @@ } | ||
export interface IfStatement extends BaseStatement { | ||
type: 'IfStatement'; | ||
type: "IfStatement"; | ||
test: Expression; | ||
@@ -165,3 +165,3 @@ consequent: Statement; | ||
export interface LabeledStatement extends BaseStatement { | ||
type: 'LabeledStatement'; | ||
type: "LabeledStatement"; | ||
label: Identifier; | ||
@@ -172,3 +172,3 @@ body: Statement; | ||
export interface BreakStatement extends BaseStatement { | ||
type: 'BreakStatement'; | ||
type: "BreakStatement"; | ||
label?: Identifier | null | undefined; | ||
@@ -178,3 +178,3 @@ } | ||
export interface ContinueStatement extends BaseStatement { | ||
type: 'ContinueStatement'; | ||
type: "ContinueStatement"; | ||
label?: Identifier | null | undefined; | ||
@@ -184,3 +184,3 @@ } | ||
export interface WithStatement extends BaseStatement { | ||
type: 'WithStatement'; | ||
type: "WithStatement"; | ||
object: Expression; | ||
@@ -191,3 +191,3 @@ body: Statement; | ||
export interface SwitchStatement extends BaseStatement { | ||
type: 'SwitchStatement'; | ||
type: "SwitchStatement"; | ||
discriminant: Expression; | ||
@@ -198,3 +198,3 @@ cases: SwitchCase[]; | ||
export interface ReturnStatement extends BaseStatement { | ||
type: 'ReturnStatement'; | ||
type: "ReturnStatement"; | ||
argument?: Expression | null | undefined; | ||
@@ -204,3 +204,3 @@ } | ||
export interface ThrowStatement extends BaseStatement { | ||
type: 'ThrowStatement'; | ||
type: "ThrowStatement"; | ||
argument: Expression; | ||
@@ -210,3 +210,3 @@ } | ||
export interface TryStatement extends BaseStatement { | ||
type: 'TryStatement'; | ||
type: "TryStatement"; | ||
block: BlockStatement; | ||
@@ -218,3 +218,3 @@ handler?: CatchClause | null | undefined; | ||
export interface WhileStatement extends BaseStatement { | ||
type: 'WhileStatement'; | ||
type: "WhileStatement"; | ||
test: Expression; | ||
@@ -225,3 +225,3 @@ body: Statement; | ||
export interface DoWhileStatement extends BaseStatement { | ||
type: 'DoWhileStatement'; | ||
type: "DoWhileStatement"; | ||
body: Statement; | ||
@@ -232,3 +232,3 @@ test: Expression; | ||
export interface ForStatement extends BaseStatement { | ||
type: 'ForStatement'; | ||
type: "ForStatement"; | ||
init?: VariableDeclaration | Expression | null | undefined; | ||
@@ -247,7 +247,7 @@ test?: Expression | null | undefined; | ||
export interface ForInStatement extends BaseForXStatement { | ||
type: 'ForInStatement'; | ||
type: "ForInStatement"; | ||
} | ||
export interface DebuggerStatement extends BaseStatement { | ||
type: 'DebuggerStatement'; | ||
type: "DebuggerStatement"; | ||
} | ||
@@ -260,3 +260,3 @@ | ||
export interface FunctionDeclaration extends BaseFunction, BaseDeclaration { | ||
type: 'FunctionDeclaration'; | ||
type: "FunctionDeclaration"; | ||
/** It is null when a function declaration is a part of the `export default function` statement */ | ||
@@ -268,9 +268,9 @@ id: Identifier | null; | ||
export interface VariableDeclaration extends BaseDeclaration { | ||
type: 'VariableDeclaration'; | ||
type: "VariableDeclaration"; | ||
declarations: VariableDeclarator[]; | ||
kind: 'var' | 'let' | 'const'; | ||
kind: "var" | "let" | "const"; | ||
} | ||
export interface VariableDeclarator extends BaseNode { | ||
type: 'VariableDeclarator'; | ||
type: "VariableDeclarator"; | ||
id: Pattern; | ||
@@ -315,3 +315,3 @@ init?: Expression | null | undefined; | ||
export interface ChainExpression extends BaseExpression { | ||
type: 'ChainExpression'; | ||
type: "ChainExpression"; | ||
expression: ChainElement; | ||
@@ -321,7 +321,7 @@ } | ||
export interface ThisExpression extends BaseExpression { | ||
type: 'ThisExpression'; | ||
type: "ThisExpression"; | ||
} | ||
export interface ArrayExpression extends BaseExpression { | ||
type: 'ArrayExpression'; | ||
type: "ArrayExpression"; | ||
elements: Array<Expression | SpreadElement | null>; | ||
@@ -331,3 +331,3 @@ } | ||
export interface ObjectExpression extends BaseExpression { | ||
type: 'ObjectExpression'; | ||
type: "ObjectExpression"; | ||
properties: Array<Property | SpreadElement>; | ||
@@ -337,3 +337,3 @@ } | ||
export interface PrivateIdentifier extends BaseNode { | ||
type: 'PrivateIdentifier'; | ||
type: "PrivateIdentifier"; | ||
name: string; | ||
@@ -343,6 +343,6 @@ } | ||
export interface Property extends BaseNode { | ||
type: 'Property'; | ||
type: "Property"; | ||
key: Expression | PrivateIdentifier; | ||
value: Expression | Pattern; // Could be an AssignmentProperty | ||
kind: 'init' | 'get' | 'set'; | ||
kind: "init" | "get" | "set"; | ||
method: boolean; | ||
@@ -354,3 +354,3 @@ shorthand: boolean; | ||
export interface PropertyDefinition extends BaseNode { | ||
type: 'PropertyDefinition'; | ||
type: "PropertyDefinition"; | ||
key: Expression | PrivateIdentifier; | ||
@@ -364,3 +364,3 @@ value?: Expression | null | undefined; | ||
id?: Identifier | null | undefined; | ||
type: 'FunctionExpression'; | ||
type: "FunctionExpression"; | ||
body: BlockStatement; | ||
@@ -370,3 +370,3 @@ } | ||
export interface SequenceExpression extends BaseExpression { | ||
type: 'SequenceExpression'; | ||
type: "SequenceExpression"; | ||
expressions: Expression[]; | ||
@@ -376,3 +376,3 @@ } | ||
export interface UnaryExpression extends BaseExpression { | ||
type: 'UnaryExpression'; | ||
type: "UnaryExpression"; | ||
operator: UnaryOperator; | ||
@@ -384,3 +384,3 @@ prefix: true; | ||
export interface BinaryExpression extends BaseExpression { | ||
type: 'BinaryExpression'; | ||
type: "BinaryExpression"; | ||
operator: BinaryOperator; | ||
@@ -392,3 +392,3 @@ left: Expression; | ||
export interface AssignmentExpression extends BaseExpression { | ||
type: 'AssignmentExpression'; | ||
type: "AssignmentExpression"; | ||
operator: AssignmentOperator; | ||
@@ -400,3 +400,3 @@ left: Pattern | MemberExpression; | ||
export interface UpdateExpression extends BaseExpression { | ||
type: 'UpdateExpression'; | ||
type: "UpdateExpression"; | ||
operator: UpdateOperator; | ||
@@ -408,3 +408,3 @@ argument: Expression; | ||
export interface LogicalExpression extends BaseExpression { | ||
type: 'LogicalExpression'; | ||
type: "LogicalExpression"; | ||
operator: LogicalOperator; | ||
@@ -416,3 +416,3 @@ left: Expression; | ||
export interface ConditionalExpression extends BaseExpression { | ||
type: 'ConditionalExpression'; | ||
type: "ConditionalExpression"; | ||
test: Expression; | ||
@@ -430,3 +430,3 @@ alternate: Expression; | ||
export interface SimpleCallExpression extends BaseCallExpression { | ||
type: 'CallExpression'; | ||
type: "CallExpression"; | ||
optional: boolean; | ||
@@ -436,7 +436,7 @@ } | ||
export interface NewExpression extends BaseCallExpression { | ||
type: 'NewExpression'; | ||
type: "NewExpression"; | ||
} | ||
export interface MemberExpression extends BaseExpression, BasePattern { | ||
type: 'MemberExpression'; | ||
type: "MemberExpression"; | ||
object: Expression | Super; | ||
@@ -453,3 +453,3 @@ property: Expression | PrivateIdentifier; | ||
export interface SwitchCase extends BaseNode { | ||
type: 'SwitchCase'; | ||
type: "SwitchCase"; | ||
test?: Expression | null | undefined; | ||
@@ -460,3 +460,3 @@ consequent: Statement[]; | ||
export interface CatchClause extends BaseNode { | ||
type: 'CatchClause'; | ||
type: "CatchClause"; | ||
param: Pattern | null; | ||
@@ -467,3 +467,3 @@ body: BlockStatement; | ||
export interface Identifier extends BaseNode, BaseExpression, BasePattern { | ||
type: 'Identifier'; | ||
type: "Identifier"; | ||
name: string; | ||
@@ -475,3 +475,3 @@ } | ||
export interface SimpleLiteral extends BaseNode, BaseExpression { | ||
type: 'Literal'; | ||
type: "Literal"; | ||
value: string | boolean | number | null; | ||
@@ -482,3 +482,3 @@ raw?: string | undefined; | ||
export interface RegExpLiteral extends BaseNode, BaseExpression { | ||
type: 'Literal'; | ||
type: "Literal"; | ||
value?: RegExp | null | undefined; | ||
@@ -493,3 +493,3 @@ regex: { | ||
export interface BigIntLiteral extends BaseNode, BaseExpression { | ||
type: 'Literal'; | ||
type: "Literal"; | ||
value?: bigint | null | undefined; | ||
@@ -500,52 +500,52 @@ bigint: string; | ||
export type UnaryOperator = '-' | '+' | '!' | '~' | 'typeof' | 'void' | 'delete'; | ||
export type UnaryOperator = "-" | "+" | "!" | "~" | "typeof" | "void" | "delete"; | ||
export type BinaryOperator = | ||
| '==' | ||
| '!=' | ||
| '===' | ||
| '!==' | ||
| '<' | ||
| '<=' | ||
| '>' | ||
| '>=' | ||
| '<<' | ||
| '>>' | ||
| '>>>' | ||
| '+' | ||
| '-' | ||
| '*' | ||
| '/' | ||
| '%' | ||
| '**' | ||
| '|' | ||
| '^' | ||
| '&' | ||
| 'in' | ||
| 'instanceof'; | ||
| "==" | ||
| "!=" | ||
| "===" | ||
| "!==" | ||
| "<" | ||
| "<=" | ||
| ">" | ||
| ">=" | ||
| "<<" | ||
| ">>" | ||
| ">>>" | ||
| "+" | ||
| "-" | ||
| "*" | ||
| "/" | ||
| "%" | ||
| "**" | ||
| "|" | ||
| "^" | ||
| "&" | ||
| "in" | ||
| "instanceof"; | ||
export type LogicalOperator = '||' | '&&' | '??'; | ||
export type LogicalOperator = "||" | "&&" | "??"; | ||
export type AssignmentOperator = | ||
| '=' | ||
| '+=' | ||
| '-=' | ||
| '*=' | ||
| '/=' | ||
| '%=' | ||
| '**=' | ||
| '<<=' | ||
| '>>=' | ||
| '>>>=' | ||
| '|=' | ||
| '^=' | ||
| '&=' | ||
| '||=' | ||
| '&&=' | ||
| '??='; | ||
| "=" | ||
| "+=" | ||
| "-=" | ||
| "*=" | ||
| "/=" | ||
| "%=" | ||
| "**=" | ||
| "<<=" | ||
| ">>=" | ||
| ">>>=" | ||
| "|=" | ||
| "^=" | ||
| "&=" | ||
| "||=" | ||
| "&&=" | ||
| "??="; | ||
export type UpdateOperator = '++' | '--'; | ||
export type UpdateOperator = "++" | "--"; | ||
export interface ForOfStatement extends BaseForXStatement { | ||
type: 'ForOfStatement'; | ||
type: "ForOfStatement"; | ||
await: boolean; | ||
@@ -555,7 +555,7 @@ } | ||
export interface Super extends BaseNode { | ||
type: 'Super'; | ||
type: "Super"; | ||
} | ||
export interface SpreadElement extends BaseNode { | ||
type: 'SpreadElement'; | ||
type: "SpreadElement"; | ||
argument: Expression; | ||
@@ -565,3 +565,3 @@ } | ||
export interface ArrowFunctionExpression extends BaseExpression, BaseFunction { | ||
type: 'ArrowFunctionExpression'; | ||
type: "ArrowFunctionExpression"; | ||
expression: boolean; | ||
@@ -572,3 +572,3 @@ body: BlockStatement | Expression; | ||
export interface YieldExpression extends BaseExpression { | ||
type: 'YieldExpression'; | ||
type: "YieldExpression"; | ||
argument?: Expression | null | undefined; | ||
@@ -579,3 +579,3 @@ delegate: boolean; | ||
export interface TemplateLiteral extends BaseExpression { | ||
type: 'TemplateLiteral'; | ||
type: "TemplateLiteral"; | ||
quasis: TemplateElement[]; | ||
@@ -586,3 +586,3 @@ expressions: Expression[]; | ||
export interface TaggedTemplateExpression extends BaseExpression { | ||
type: 'TaggedTemplateExpression'; | ||
type: "TaggedTemplateExpression"; | ||
tag: Expression; | ||
@@ -593,3 +593,3 @@ quasi: TemplateLiteral; | ||
export interface TemplateElement extends BaseNode { | ||
type: 'TemplateElement'; | ||
type: "TemplateElement"; | ||
tail: boolean; | ||
@@ -605,3 +605,3 @@ value: { | ||
value: Pattern; | ||
kind: 'init'; | ||
kind: "init"; | ||
method: boolean; // false | ||
@@ -611,3 +611,3 @@ } | ||
export interface ObjectPattern extends BasePattern { | ||
type: 'ObjectPattern'; | ||
type: "ObjectPattern"; | ||
properties: Array<AssignmentProperty | RestElement>; | ||
@@ -617,3 +617,3 @@ } | ||
export interface ArrayPattern extends BasePattern { | ||
type: 'ArrayPattern'; | ||
type: "ArrayPattern"; | ||
elements: Array<Pattern | null>; | ||
@@ -623,3 +623,3 @@ } | ||
export interface RestElement extends BasePattern { | ||
type: 'RestElement'; | ||
type: "RestElement"; | ||
argument: Pattern; | ||
@@ -629,3 +629,3 @@ } | ||
export interface AssignmentPattern extends BasePattern { | ||
type: 'AssignmentPattern'; | ||
type: "AssignmentPattern"; | ||
left: Pattern; | ||
@@ -642,3 +642,3 @@ right: Expression; | ||
export interface ClassBody extends BaseNode { | ||
type: 'ClassBody'; | ||
type: "ClassBody"; | ||
body: Array<MethodDefinition | PropertyDefinition | StaticBlock>; | ||
@@ -648,6 +648,6 @@ } | ||
export interface MethodDefinition extends BaseNode { | ||
type: 'MethodDefinition'; | ||
type: "MethodDefinition"; | ||
key: Expression | PrivateIdentifier; | ||
value: FunctionExpression; | ||
kind: 'constructor' | 'method' | 'get' | 'set'; | ||
kind: "constructor" | "method" | "get" | "set"; | ||
computed: boolean; | ||
@@ -658,3 +658,3 @@ static: boolean; | ||
export interface ClassDeclaration extends BaseClass, BaseDeclaration { | ||
type: 'ClassDeclaration'; | ||
type: "ClassDeclaration"; | ||
/** It is null when a class declaration is a part of the `export default class` statement */ | ||
@@ -665,3 +665,3 @@ id: Identifier | null; | ||
export interface ClassExpression extends BaseClass, BaseExpression { | ||
type: 'ClassExpression'; | ||
type: "ClassExpression"; | ||
id?: Identifier | null | undefined; | ||
@@ -671,3 +671,3 @@ } | ||
export interface MetaProperty extends BaseExpression { | ||
type: 'MetaProperty'; | ||
type: "MetaProperty"; | ||
meta: Identifier; | ||
@@ -690,3 +690,3 @@ property: Identifier; | ||
export interface ImportDeclaration extends BaseModuleDeclaration { | ||
type: 'ImportDeclaration'; | ||
type: "ImportDeclaration"; | ||
specifiers: Array<ImportSpecifier | ImportDefaultSpecifier | ImportNamespaceSpecifier>; | ||
@@ -697,3 +697,3 @@ source: Literal; | ||
export interface ImportSpecifier extends BaseModuleSpecifier { | ||
type: 'ImportSpecifier'; | ||
type: "ImportSpecifier"; | ||
imported: Identifier; | ||
@@ -703,3 +703,3 @@ } | ||
export interface ImportExpression extends BaseExpression { | ||
type: 'ImportExpression'; | ||
type: "ImportExpression"; | ||
source: Expression; | ||
@@ -709,11 +709,11 @@ } | ||
export interface ImportDefaultSpecifier extends BaseModuleSpecifier { | ||
type: 'ImportDefaultSpecifier'; | ||
type: "ImportDefaultSpecifier"; | ||
} | ||
export interface ImportNamespaceSpecifier extends BaseModuleSpecifier { | ||
type: 'ImportNamespaceSpecifier'; | ||
type: "ImportNamespaceSpecifier"; | ||
} | ||
export interface ExportNamedDeclaration extends BaseModuleDeclaration { | ||
type: 'ExportNamedDeclaration'; | ||
type: "ExportNamedDeclaration"; | ||
declaration?: Declaration | null | undefined; | ||
@@ -725,3 +725,3 @@ specifiers: ExportSpecifier[]; | ||
export interface ExportSpecifier extends BaseModuleSpecifier { | ||
type: 'ExportSpecifier'; | ||
type: "ExportSpecifier"; | ||
exported: Identifier; | ||
@@ -731,3 +731,3 @@ } | ||
export interface ExportDefaultDeclaration extends BaseModuleDeclaration { | ||
type: 'ExportDefaultDeclaration'; | ||
type: "ExportDefaultDeclaration"; | ||
declaration: Declaration | Expression; | ||
@@ -737,3 +737,3 @@ } | ||
export interface ExportAllDeclaration extends BaseModuleDeclaration { | ||
type: 'ExportAllDeclaration'; | ||
type: "ExportAllDeclaration"; | ||
exported: Identifier | null; | ||
@@ -744,4 +744,4 @@ source: Literal; | ||
export interface AwaitExpression extends BaseExpression { | ||
type: 'AwaitExpression'; | ||
type: "AwaitExpression"; | ||
argument: Expression; | ||
} |
{ | ||
"name": "@types/estree", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"description": "TypeScript definitions for estree", | ||
@@ -23,4 +23,4 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/estree", | ||
"dependencies": {}, | ||
"typesPublisherContentHash": "6bb5253923dc858fe2d49a5555adfc2902dcbdb5536fa2b595339f0b498c29cf", | ||
"typeScriptVersion": "4.3" | ||
"typesPublisherContentHash": "00c2c4d477c1ec5ae01786562bcd553116a4ecb2d8c6d0482a9186c7ba63f10f", | ||
"typeScriptVersion": "4.5" | ||
} |
@@ -11,3 +11,3 @@ # Installation | ||
### Additional Details | ||
* Last updated: Wed, 19 Apr 2023 05:02:44 GMT | ||
* Last updated: Sat, 23 Sep 2023 17:07:22 GMT | ||
* Dependencies: none | ||
@@ -14,0 +14,0 @@ * Global values: none |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package