@swc/core 1.3.16 → 1.3.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -5,6 +5,73 @@
5
5
 
6
6
 
7
7
 
8
+ - **(es/minifier)** Fix code for dropping unreachable statements (#6429) ([bb544ba](https://github.com/swc-project/swc/commit/bb544ba2f58531e2cf984bbbaf2f819a1e4d8ada))
9
+
10
+
11
+ - **(es/modules)** Fix `jsc.paths` (#6454) ([05d185d](https://github.com/swc-project/swc/commit/05d185d59b4e8f7259a1f9908c25cf9e288b92af))
12
+
13
+
14
+ - **(es/plugins/proxy)** Adjust import with compile time flags (#6451) ([f14b156](https://github.com/swc-project/swc/commit/f14b156a60bd6b54b08b17e76accb5c108d27679))
15
+
16
+
17
+ - **(html/minifier)** Fix script/style merging (#6443) ([1dfd8ce](https://github.com/swc-project/swc/commit/1dfd8cef88b16180e6525b524637fd3eb627b857))
18
+
19
+
20
+ - **(xml/parser)** Fix parsing of pi (#6450) ([6388920](https://github.com/swc-project/swc/commit/638892071a8713a278c114aae6fedc74f77a8cc0))
21
+
22
+ ### Features
23
+
24
+
25
+
26
+ - **(css/parser)** Add `parse_string_input` (#6441) ([9600308](https://github.com/swc-project/swc/commit/9600308108daa60c142a5a6fddc9c6ef94c12b80))
27
+
28
+ ## [1.3.17] - 2022-11-15
29
+
30
+ ### Bug Fixes
31
+
32
+
33
+
34
+ - **(bindings)** Revert #6436 (#6444) ([948e35b](https://github.com/swc-project/swc/commit/948e35bcd66b98c460d67b4d58f536ea4d3d5992))
35
+
36
+
37
+ - **(css/parser)** Fix a bug with scope in block (#6402) ([3d7545d](https://github.com/swc-project/swc/commit/3d7545d89bf6a7675cd511217b6c024889476fc8))
38
+
39
+
40
+ - **(es/compat)** Improve `destructuring` pass (#6412) ([6728603](https://github.com/swc-project/swc/commit/67286032b1bd75ef1dac51201fe5ff65143f565a))
41
+
42
+
43
+ - **(es/compat)** Fix span hygiene of function naming pass (#6345) ([81a4bb3](https://github.com/swc-project/swc/commit/81a4bb304a2790dab9448c88887a78430792ed38))
44
+
45
+
46
+ - **(es/minifier)** Preserve op of the op-assignments in seq inliner (#6428) ([5fd7ab8](https://github.com/swc-project/swc/commit/5fd7ab87b69ed99bee1dfdbe39ed2182e0182a75))
47
+
48
+
49
+ - **(es/minifier)** Change the default of `mangle.toplevel` to false (#6439) ([99934b0](https://github.com/swc-project/swc/commit/99934b09f70f9fb594e3291a9d96b79685919b13))
50
+
51
+
52
+ - **(es/modules)** Fix `jsc.paths` of `.ts` imports (#6431) ([9c9c3eb](https://github.com/swc-project/swc/commit/9c9c3ebd2c9c4141e3449e19926636a77741980a))
53
+
54
+ ### Miscellaneous Tasks
55
+
56
+
57
+
58
+ - **(ci)** Ensure to honor node package manager (#6437) ([8ca3cc7](https://github.com/swc-project/swc/commit/8ca3cc7875b1fc3fc4db107980f59de46b4e6c81))
59
+
60
+ ### Refactor
61
+
62
+
63
+
64
+ - **(bindings)** Deprecate `JsValue::*_serde` (#6436) ([1dd8b3d](https://github.com/swc-project/swc/commit/1dd8b3d9d5393fa382345dce3d6977f7d4b5aa63))
65
+
66
+
67
+ - **(es/plugins)** Simplify `read_result_*` (#6426) ([7a1c2a1](https://github.com/swc-project/swc/commit/7a1c2a1e2ca98cb897899b1a5def7dba7b6a8b5c))
68
+
69
+ ## [1.3.16] - 2022-11-13
70
+
71
+ ### Bug Fixes
72
+
73
+
74
+
8
75
  - **(es/utils)** Verify the name of an alias (#6423) ([68ffc5b](https://github.com/swc-project/swc/commit/68ffc5bc3e676340cda1ee76265e12420d52473e))
9
76
 
10
77
  ## [1.3.15] - 2022-11-12
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@swc/core",
3
- "version": "1.3.16",
3
+ "version": "1.3.18",
4
4
  "description": "Super-fast alternative for babel",
5
5
  "homepage": "https://swc.rs",
6
6
  "main": "./index.js",
@@ -141,16 +141,16 @@
141
141
  "url": "https://opencollective.com/swc"
142
142
  },
143
143
  "optionalDependencies": {
144
- "@swc/core-win32-x64-msvc": "1.3.16",
145
- "@swc/core-darwin-x64": "1.3.16",
146
- "@swc/core-linux-x64-gnu": "1.3.16",
147
- "@swc/core-linux-x64-musl": "1.3.16",
148
- "@swc/core-win32-ia32-msvc": "1.3.16",
149
- "@swc/core-linux-arm64-gnu": "1.3.16",
150
- "@swc/core-linux-arm-gnueabihf": "1.3.16",
151
- "@swc/core-darwin-arm64": "1.3.16",
152
- "@swc/core-linux-arm64-musl": "1.3.16",
153
- "@swc/core-win32-arm64-msvc": "1.3.16"
144
+ "@swc/core-win32-x64-msvc": "1.3.18",
145
+ "@swc/core-darwin-x64": "1.3.18",
146
+ "@swc/core-linux-x64-gnu": "1.3.18",
147
+ "@swc/core-linux-x64-musl": "1.3.18",
148
+ "@swc/core-win32-ia32-msvc": "1.3.18",
149
+ "@swc/core-linux-arm64-gnu": "1.3.18",
150
+ "@swc/core-linux-arm-gnueabihf": "1.3.18",
151
+ "@swc/core-darwin-arm64": "1.3.18",
152
+ "@swc/core-linux-arm64-musl": "1.3.18",
153
+ "@swc/core-win32-arm64-msvc": "1.3.18"
154
154
  },
155
155
  "files": [
156
156
  "CHANGELOG.md",
package/spack.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { Options } from "./types";
2
- export declare type BundleInput = BundleOptions | BundleOptions[];
2
+ export type BundleInput = BundleOptions | BundleOptions[];
3
3
  export declare function compileBundleOptions(config: BundleInput | string | undefined): Promise<BundleInput>;
4
4
  /**
5
5
  * Usage: In `spack.config.js` / `spack.config.ts`, you can utilize type annotations (to get autocompletions) like
@@ -43,8 +43,8 @@ export interface OutputConfig {
43
43
  }
44
44
  export interface ModuleConfig {
45
45
  }
46
- export declare type Mode = 'production' | 'development' | 'none';
47
- export declare type Target = 'browser' | 'node';
48
- export declare type EntryConfig = string | string[] | {
46
+ export type Mode = 'production' | 'development' | 'none';
47
+ export type Target = 'browser' | 'node';
48
+ export type EntryConfig = string | string[] | {
49
49
  [name: string]: string;
50
50
  };
package/types.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  export interface Plugin {
2
2
  (module: Program): Program;
3
3
  }
4
- export declare type ParseOptions = ParserConfig & {
4
+ export type ParseOptions = ParserConfig & {
5
5
  comments?: boolean;
6
6
  script?: boolean;
7
7
  /**
@@ -9,7 +9,7 @@ export declare type ParseOptions = ParserConfig & {
9
9
  */
10
10
  target?: JscTarget;
11
11
  };
12
- export declare type TerserEcmaVersion = 5 | 2015 | 2016 | string | number;
12
+ export type TerserEcmaVersion = 5 | 2015 | 2016 | string | number;
13
13
  export interface JsMinifyOptions {
14
14
  compress?: TerserCompressOptions | boolean;
15
15
  format?: JsFormatOptions & ToSnakeCaseProperties<JsFormatOptions>;
@@ -27,11 +27,11 @@ export interface JsMinifyOptions {
27
27
  /**
28
28
  * @example ToSnakeCase<'indentLevel'> == 'indent_level'
29
29
  */
30
- declare type ToSnakeCase<T extends string> = T extends `${infer A}${infer B}` ? `${A extends Lowercase<A> ? A : `_${Lowercase<A>}`}${ToSnakeCase<B>}` : T;
30
+ type ToSnakeCase<T extends string> = T extends `${infer A}${infer B}` ? `${A extends Lowercase<A> ? A : `_${Lowercase<A>}`}${ToSnakeCase<B>}` : T;
31
31
  /**
32
32
  * @example ToSnakeCaseProperties<{indentLevel: 3}> == {indent_level: 3}
33
33
  */
34
- declare type ToSnakeCaseProperties<T> = {
34
+ type ToSnakeCaseProperties<T> = {
35
35
  [K in keyof T as (K extends string ? ToSnakeCase<K> : K)]: T[K];
36
36
  };
37
37
  /**
@@ -374,7 +374,7 @@ export interface CallerOptions {
374
374
  name: string;
375
375
  [key: string]: any;
376
376
  }
377
- export declare type Swcrc = Config | Config[];
377
+ export type Swcrc = Config | Config[];
378
378
  /**
379
379
  * .swcrc
380
380
  */
@@ -473,8 +473,8 @@ export interface JscConfig {
473
473
  minify?: JsMinifyOptions;
474
474
  preserveAllComments?: boolean;
475
475
  }
476
- export declare type JscTarget = "es3" | "es5" | "es2015" | "es2016" | "es2017" | "es2018" | "es2019" | "es2020" | "es2021" | "es2022";
477
- export declare type ParserConfig = TsParserConfig | EsParserConfig;
476
+ export type JscTarget = "es3" | "es5" | "es2015" | "es2016" | "es2017" | "es2018" | "es2019" | "es2020" | "es2021" | "es2022";
477
+ export type ParserConfig = TsParserConfig | EsParserConfig;
478
478
  export interface TsParserConfig {
479
479
  syntax: "typescript";
480
480
  /**
@@ -667,7 +667,7 @@ export interface GlobalPassOption {
667
667
  */
668
668
  envs?: string[];
669
669
  }
670
- export declare type ModuleConfig = Es6Config | CommonJsConfig | UmdConfig | AmdConfig | NodeNextConfig | SystemjsConfig;
670
+ export type ModuleConfig = Es6Config | CommonJsConfig | UmdConfig | AmdConfig | NodeNextConfig | SystemjsConfig;
671
671
  export interface BaseModuleConfig {
672
672
  /**
673
673
  * By default, when using exports with babel a non-enumerable `__esModule`
@@ -885,7 +885,7 @@ export interface Class extends HasSpan, HasDecorator {
885
885
  superTypeParams?: TsTypeParameterInstantiation;
886
886
  implements: TsExpressionWithTypeArguments[];
887
887
  }
888
- export declare type ClassMember = Constructor | ClassMethod | PrivateMethod | ClassProperty | PrivateProperty | TsIndexSignature | EmptyStatement | StaticBlock;
888
+ export type ClassMember = Constructor | ClassMethod | PrivateMethod | ClassProperty | PrivateProperty | TsIndexSignature | EmptyStatement | StaticBlock;
889
889
  export interface ClassPropertyBase extends Node, HasSpan, HasDecorator {
890
890
  value?: Expression;
891
891
  typeAnnotation?: TsTypeAnnotation;
@@ -943,8 +943,8 @@ export interface Decorator extends Node, HasSpan {
943
943
  type: "Decorator";
944
944
  expression: Expression;
945
945
  }
946
- export declare type MethodKind = "method" | "getter" | "setter";
947
- export declare type Declaration = ClassDeclaration | FunctionDeclaration | VariableDeclaration | TsInterfaceDeclaration | TsTypeAliasDeclaration | TsEnumDeclaration | TsModuleDeclaration;
946
+ export type MethodKind = "method" | "getter" | "setter";
947
+ export type Declaration = ClassDeclaration | FunctionDeclaration | VariableDeclaration | TsInterfaceDeclaration | TsTypeAliasDeclaration | TsEnumDeclaration | TsModuleDeclaration;
948
948
  export interface FunctionDeclaration extends Fn {
949
949
  type: "FunctionDeclaration";
950
950
  identifier: Identifier;
@@ -961,14 +961,14 @@ export interface VariableDeclaration extends Node, HasSpan {
961
961
  declare: boolean;
962
962
  declarations: VariableDeclarator[];
963
963
  }
964
- export declare type VariableDeclarationKind = "var" | "let" | "const";
964
+ export type VariableDeclarationKind = "var" | "let" | "const";
965
965
  export interface VariableDeclarator extends Node, HasSpan {
966
966
  type: "VariableDeclarator";
967
967
  id: Pattern;
968
968
  init?: Expression;
969
969
  definite: boolean;
970
970
  }
971
- export declare type Expression = ThisExpression | ArrayExpression | ObjectExpression | FunctionExpression | UnaryExpression | UpdateExpression | BinaryExpression | AssignmentExpression | MemberExpression | SuperPropExpression | ConditionalExpression | CallExpression | NewExpression | SequenceExpression | Identifier | Literal | TemplateLiteral | TaggedTemplateExpression | ArrowFunctionExpression | ClassExpression | YieldExpression | MetaProperty | AwaitExpression | ParenthesisExpression | JSXMemberExpression | JSXNamespacedName | JSXEmptyExpression | JSXElement | JSXFragment | TsTypeAssertion | TsConstAssertion | TsNonNullExpression | TsAsExpression | TsInstantiation | PrivateName | OptionalChainingExpression | Invalid;
971
+ export type Expression = ThisExpression | ArrayExpression | ObjectExpression | FunctionExpression | UnaryExpression | UpdateExpression | BinaryExpression | AssignmentExpression | MemberExpression | SuperPropExpression | ConditionalExpression | CallExpression | NewExpression | SequenceExpression | Identifier | Literal | TemplateLiteral | TaggedTemplateExpression | ArrowFunctionExpression | ClassExpression | YieldExpression | MetaProperty | AwaitExpression | ParenthesisExpression | JSXMemberExpression | JSXNamespacedName | JSXEmptyExpression | JSXElement | JSXFragment | TsTypeAssertion | TsConstAssertion | TsNonNullExpression | TsAsExpression | TsInstantiation | PrivateName | OptionalChainingExpression | Invalid;
972
972
  interface ExpressionBase extends Node, HasSpan {
973
973
  }
974
974
  export interface Identifier extends ExpressionBase {
@@ -1141,7 +1141,7 @@ export interface PrivateName extends ExpressionBase {
1141
1141
  type: "PrivateName";
1142
1142
  id: Identifier;
1143
1143
  }
1144
- export declare type JSXObject = JSXMemberExpression | Identifier;
1144
+ export type JSXObject = JSXMemberExpression | Identifier;
1145
1145
  export interface JSXMemberExpression extends Node {
1146
1146
  type: "JSXMemberExpression";
1147
1147
  object: JSXObject;
@@ -1162,12 +1162,12 @@ export interface JSXExpressionContainer extends Node, HasSpan {
1162
1162
  type: "JSXExpressionContainer";
1163
1163
  expression: JSXExpression;
1164
1164
  }
1165
- export declare type JSXExpression = JSXEmptyExpression | Expression;
1165
+ export type JSXExpression = JSXEmptyExpression | Expression;
1166
1166
  export interface JSXSpreadChild extends Node, HasSpan {
1167
1167
  type: "JSXSpreadChild";
1168
1168
  expression: Expression;
1169
1169
  }
1170
- export declare type JSXElementName = Identifier | JSXMemberExpression | JSXNamespacedName;
1170
+ export type JSXElementName = Identifier | JSXMemberExpression | JSXNamespacedName;
1171
1171
  export interface JSXOpeningElement extends Node, HasSpan {
1172
1172
  type: "JSXOpeningElement";
1173
1173
  name: JSXElementName;
@@ -1175,7 +1175,7 @@ export interface JSXOpeningElement extends Node, HasSpan {
1175
1175
  selfClosing: boolean;
1176
1176
  typeArguments?: TsTypeParameterInstantiation;
1177
1177
  }
1178
- export declare type JSXAttributeOrSpread = JSXAttribute | SpreadElement;
1178
+ export type JSXAttributeOrSpread = JSXAttribute | SpreadElement;
1179
1179
  export interface JSXClosingElement extends Node, HasSpan {
1180
1180
  type: "JSXClosingElement";
1181
1181
  name: JSXElementName;
@@ -1185,8 +1185,8 @@ export interface JSXAttribute extends Node, HasSpan {
1185
1185
  name: JSXAttributeName;
1186
1186
  value?: JSXAttrValue;
1187
1187
  }
1188
- export declare type JSXAttributeName = Identifier | JSXNamespacedName;
1189
- export declare type JSXAttrValue = Literal | JSXExpressionContainer | JSXElement | JSXFragment;
1188
+ export type JSXAttributeName = Identifier | JSXNamespacedName;
1189
+ export type JSXAttrValue = Literal | JSXExpressionContainer | JSXElement | JSXFragment;
1190
1190
  export interface JSXText extends Node, HasSpan {
1191
1191
  type: "JSXText";
1192
1192
  value: string;
@@ -1198,7 +1198,7 @@ export interface JSXElement extends Node, HasSpan {
1198
1198
  children: JSXElementChild[];
1199
1199
  closing?: JSXClosingElement;
1200
1200
  }
1201
- export declare type JSXElementChild = JSXText | JSXExpressionContainer | JSXSpreadChild | JSXElement | JSXFragment;
1201
+ export type JSXElementChild = JSXText | JSXExpressionContainer | JSXSpreadChild | JSXElement | JSXFragment;
1202
1202
  export interface JSXFragment extends Node, HasSpan {
1203
1203
  type: "JSXFragment";
1204
1204
  opening: JSXOpeningFragment;
@@ -1211,7 +1211,7 @@ export interface JSXOpeningFragment extends Node, HasSpan {
1211
1211
  export interface JSXClosingFragment extends Node, HasSpan {
1212
1212
  type: "JSXClosingFragment";
1213
1213
  }
1214
- export declare type Literal = StringLiteral | BooleanLiteral | NullLiteral | NumericLiteral | BigIntLiteral | RegExpLiteral | JSXText;
1214
+ export type Literal = StringLiteral | BooleanLiteral | NullLiteral | NumericLiteral | BigIntLiteral | RegExpLiteral | JSXText;
1215
1215
  export interface StringLiteral extends Node, HasSpan {
1216
1216
  type: "StringLiteral";
1217
1217
  value: string;
@@ -1239,7 +1239,7 @@ export interface BigIntLiteral extends Node, HasSpan {
1239
1239
  value: bigint;
1240
1240
  raw?: string;
1241
1241
  }
1242
- export declare type ModuleDeclaration = ImportDeclaration | ExportDeclaration | ExportNamedDeclaration | ExportDefaultDeclaration | ExportDefaultExpression | ExportAllDeclaration | TsImportEqualsDeclaration | TsExportAssignment | TsNamespaceExportDeclaration;
1242
+ export type ModuleDeclaration = ImportDeclaration | ExportDeclaration | ExportNamedDeclaration | ExportDefaultDeclaration | ExportDefaultExpression | ExportAllDeclaration | TsImportEqualsDeclaration | TsExportAssignment | TsNamespaceExportDeclaration;
1243
1243
  export interface ExportDefaultExpression extends Node, HasSpan {
1244
1244
  type: "ExportDefaultExpression";
1245
1245
  expression: Expression;
@@ -1275,8 +1275,8 @@ export interface ExportDefaultDeclaration extends Node, HasSpan {
1275
1275
  type: "ExportDefaultDeclaration";
1276
1276
  decl: DefaultDecl;
1277
1277
  }
1278
- export declare type DefaultDecl = ClassExpression | FunctionExpression | TsInterfaceDeclaration;
1279
- export declare type ImportSpecifier = NamedImportSpecifier | ImportDefaultSpecifier | ImportNamespaceSpecifier;
1278
+ export type DefaultDecl = ClassExpression | FunctionExpression | TsInterfaceDeclaration;
1279
+ export type ImportSpecifier = NamedImportSpecifier | ImportDefaultSpecifier | ImportNamespaceSpecifier;
1280
1280
  /**
1281
1281
  * e.g. `import foo from 'mod.js'`
1282
1282
  */
@@ -1306,8 +1306,8 @@ export interface NamedImportSpecifier extends Node, HasSpan {
1306
1306
  imported?: ModuleExportName;
1307
1307
  isTypeOnly: boolean;
1308
1308
  }
1309
- export declare type ModuleExportName = Identifier | StringLiteral;
1310
- export declare type ExportSpecifier = ExportNamespaceSpecifier | ExportDefaultSpecifier | NamedExportSpecifier;
1309
+ export type ModuleExportName = Identifier | StringLiteral;
1310
+ export type ExportSpecifier = ExportNamespaceSpecifier | ExportDefaultSpecifier | NamedExportSpecifier;
1311
1311
  /**
1312
1312
  * `export * as foo from 'src';`
1313
1313
  */
@@ -1334,7 +1334,7 @@ interface HasInterpreter {
1334
1334
  */
1335
1335
  interpreter: string;
1336
1336
  }
1337
- export declare type Program = Module | Script;
1337
+ export type Program = Module | Script;
1338
1338
  export interface Module extends Node, HasSpan, HasInterpreter {
1339
1339
  type: "Module";
1340
1340
  body: ModuleItem[];
@@ -1343,12 +1343,12 @@ export interface Script extends Node, HasSpan, HasInterpreter {
1343
1343
  type: "Script";
1344
1344
  body: Statement[];
1345
1345
  }
1346
- export declare type ModuleItem = ModuleDeclaration | Statement;
1347
- export declare type BinaryOperator = "==" | "!=" | "===" | "!==" | "<" | "<=" | ">" | ">=" | "<<" | ">>" | ">>>" | "+" | "-" | "*" | "/" | "%" | "|" | "^" | "&" | "||" | "&&" | "in" | "instanceof" | "**" | "??";
1348
- export declare type AssignmentOperator = "=" | "+=" | "-=" | "*=" | "/=" | "%=" | "<<=" | ">>=" | ">>>=" | "|=" | "^=" | "&=" | "**=" | "&&=" | "||=" | "??=";
1349
- export declare type UpdateOperator = "++" | "--";
1350
- export declare type UnaryOperator = "-" | "+" | "!" | "~" | "typeof" | "void" | "delete";
1351
- export declare type Pattern = BindingIdentifier | ArrayPattern | RestElement | ObjectPattern | AssignmentPattern | Invalid | Expression;
1346
+ export type ModuleItem = ModuleDeclaration | Statement;
1347
+ export type BinaryOperator = "==" | "!=" | "===" | "!==" | "<" | "<=" | ">" | ">=" | "<<" | ">>" | ">>>" | "+" | "-" | "*" | "/" | "%" | "|" | "^" | "&" | "||" | "&&" | "in" | "instanceof" | "**" | "??";
1348
+ export type AssignmentOperator = "=" | "+=" | "-=" | "*=" | "/=" | "%=" | "<<=" | ">>=" | ">>>=" | "|=" | "^=" | "&=" | "**=" | "&&=" | "||=" | "??=";
1349
+ export type UpdateOperator = "++" | "--";
1350
+ export type UnaryOperator = "-" | "+" | "!" | "~" | "typeof" | "void" | "delete";
1351
+ export type Pattern = BindingIdentifier | ArrayPattern | RestElement | ObjectPattern | AssignmentPattern | Invalid | Expression;
1352
1352
  export interface BindingIdentifier extends PatternBase {
1353
1353
  type: "Identifier";
1354
1354
  value: string;
@@ -1374,7 +1374,7 @@ export interface RestElement extends PatternBase {
1374
1374
  rest: Span;
1375
1375
  argument: Pattern;
1376
1376
  }
1377
- export declare type ObjectPatternProperty = KeyValuePatternProperty | AssignmentPatternProperty | RestElement;
1377
+ export type ObjectPatternProperty = KeyValuePatternProperty | AssignmentPatternProperty | RestElement;
1378
1378
  /**
1379
1379
  * `{key: value}`
1380
1380
  */
@@ -1392,7 +1392,7 @@ export interface AssignmentPatternProperty extends Node, HasSpan {
1392
1392
  value?: Expression;
1393
1393
  }
1394
1394
  /** Identifier is `a` in `{ a, }` */
1395
- export declare type Property = Identifier | KeyValueProperty | AssignmentProperty | GetterProperty | SetterProperty | MethodProperty;
1395
+ export type Property = Identifier | KeyValueProperty | AssignmentProperty | GetterProperty | SetterProperty | MethodProperty;
1396
1396
  interface PropBase extends Node {
1397
1397
  key: PropertyName;
1398
1398
  }
@@ -1418,7 +1418,7 @@ export interface SetterProperty extends PropBase, HasSpan {
1418
1418
  export interface MethodProperty extends PropBase, Fn {
1419
1419
  type: "MethodProperty";
1420
1420
  }
1421
- export declare type PropertyName = Identifier | StringLiteral | NumericLiteral | ComputedPropName | BigIntLiteral;
1421
+ export type PropertyName = Identifier | StringLiteral | NumericLiteral | ComputedPropName | BigIntLiteral;
1422
1422
  export interface ComputedPropName extends Node, HasSpan {
1423
1423
  type: "Computed";
1424
1424
  expression: Expression;
@@ -1431,7 +1431,7 @@ export interface ExpressionStatement extends Node, HasSpan {
1431
1431
  type: "ExpressionStatement";
1432
1432
  expression: Expression;
1433
1433
  }
1434
- export declare type Statement = BlockStatement | EmptyStatement | DebuggerStatement | WithStatement | ReturnStatement | LabeledStatement | BreakStatement | ContinueStatement | IfStatement | SwitchStatement | ThrowStatement | TryStatement | WhileStatement | DoWhileStatement | ForStatement | ForInStatement | ForOfStatement | Declaration | ExpressionStatement;
1434
+ export type Statement = BlockStatement | EmptyStatement | DebuggerStatement | WithStatement | ReturnStatement | LabeledStatement | BreakStatement | ContinueStatement | IfStatement | SwitchStatement | ThrowStatement | TryStatement | WhileStatement | DoWhileStatement | ForStatement | ForInStatement | ForOfStatement | Declaration | ExpressionStatement;
1435
1435
  export interface EmptyStatement extends Node, HasSpan {
1436
1436
  type: "EmptyStatement";
1437
1437
  }
@@ -1559,14 +1559,14 @@ export interface TsParameterProperty extends Node, HasSpan, HasDecorator {
1559
1559
  readonly: boolean;
1560
1560
  param: TsParameterPropertyParameter;
1561
1561
  }
1562
- export declare type TsParameterPropertyParameter = BindingIdentifier | AssignmentPattern;
1562
+ export type TsParameterPropertyParameter = BindingIdentifier | AssignmentPattern;
1563
1563
  export interface TsQualifiedName extends Node {
1564
1564
  type: "TsQualifiedName";
1565
1565
  left: TsEntityName;
1566
1566
  right: Identifier;
1567
1567
  }
1568
- export declare type TsEntityName = TsQualifiedName | Identifier;
1569
- export declare type TsTypeElement = TsCallSignatureDeclaration | TsConstructSignatureDeclaration | TsPropertySignature | TsGetterSignature | TsSetterSignature | TsMethodSignature | TsIndexSignature;
1568
+ export type TsEntityName = TsQualifiedName | Identifier;
1569
+ export type TsTypeElement = TsCallSignatureDeclaration | TsConstructSignatureDeclaration | TsPropertySignature | TsGetterSignature | TsSetterSignature | TsMethodSignature | TsIndexSignature;
1570
1570
  export interface TsCallSignatureDeclaration extends Node, HasSpan {
1571
1571
  type: "TsCallSignatureDeclaration";
1572
1572
  params: TsFnParameter[];
@@ -1623,17 +1623,17 @@ export interface TsIndexSignature extends Node, HasSpan {
1623
1623
  readonly: boolean;
1624
1624
  static: boolean;
1625
1625
  }
1626
- export declare type TsType = TsKeywordType | TsThisType | TsFnOrConstructorType | TsTypeReference | TsTypeQuery | TsTypeLiteral | TsArrayType | TsTupleType | TsOptionalType | TsRestType | TsUnionOrIntersectionType | TsConditionalType | TsInferType | TsParenthesizedType | TsTypeOperator | TsIndexedAccessType | TsMappedType | TsLiteralType | TsTypePredicate | TsImportType;
1627
- export declare type TsFnOrConstructorType = TsFunctionType | TsConstructorType;
1626
+ export type TsType = TsKeywordType | TsThisType | TsFnOrConstructorType | TsTypeReference | TsTypeQuery | TsTypeLiteral | TsArrayType | TsTupleType | TsOptionalType | TsRestType | TsUnionOrIntersectionType | TsConditionalType | TsInferType | TsParenthesizedType | TsTypeOperator | TsIndexedAccessType | TsMappedType | TsLiteralType | TsTypePredicate | TsImportType;
1627
+ export type TsFnOrConstructorType = TsFunctionType | TsConstructorType;
1628
1628
  export interface TsKeywordType extends Node, HasSpan {
1629
1629
  type: "TsKeywordType";
1630
1630
  kind: TsKeywordTypeKind;
1631
1631
  }
1632
- export declare type TsKeywordTypeKind = "any" | "unknown" | "number" | "object" | "boolean" | "bigint" | "string" | "symbol" | "void" | "undefined" | "null" | "never" | "intrinsic";
1632
+ export type TsKeywordTypeKind = "any" | "unknown" | "number" | "object" | "boolean" | "bigint" | "string" | "symbol" | "void" | "undefined" | "null" | "never" | "intrinsic";
1633
1633
  export interface TsThisType extends Node, HasSpan {
1634
1634
  type: "TsThisType";
1635
1635
  }
1636
- export declare type TsFnParameter = BindingIdentifier | ArrayPattern | RestElement | ObjectPattern;
1636
+ export type TsFnParameter = BindingIdentifier | ArrayPattern | RestElement | ObjectPattern;
1637
1637
  export interface TsFunctionType extends Node, HasSpan {
1638
1638
  type: "TsFunctionType";
1639
1639
  params: TsFnParameter[];
@@ -1658,7 +1658,7 @@ export interface TsTypePredicate extends Node, HasSpan {
1658
1658
  paramName: TsThisTypeOrIdent;
1659
1659
  typeAnnotation?: TsTypeAnnotation;
1660
1660
  }
1661
- export declare type TsThisTypeOrIdent = TsThisType | Identifier;
1661
+ export type TsThisTypeOrIdent = TsThisType | Identifier;
1662
1662
  export interface TsImportType extends Node, HasSpan {
1663
1663
  type: "TsImportType";
1664
1664
  argument: StringLiteral;
@@ -1673,7 +1673,7 @@ export interface TsTypeQuery extends Node, HasSpan {
1673
1673
  exprName: TsTypeQueryExpr;
1674
1674
  typeArguments?: TsTypeParameterInstantiation;
1675
1675
  }
1676
- export declare type TsTypeQueryExpr = TsEntityName | TsImportType;
1676
+ export type TsTypeQueryExpr = TsEntityName | TsImportType;
1677
1677
  export interface TsTypeLiteral extends Node, HasSpan {
1678
1678
  type: "TsTypeLiteral";
1679
1679
  members: TsTypeElement[];
@@ -1699,7 +1699,7 @@ export interface TsRestType extends Node, HasSpan {
1699
1699
  type: "TsRestType";
1700
1700
  typeAnnotation: TsType;
1701
1701
  }
1702
- export declare type TsUnionOrIntersectionType = TsUnionType | TsIntersectionType;
1702
+ export type TsUnionOrIntersectionType = TsUnionType | TsIntersectionType;
1703
1703
  export interface TsUnionType extends Node, HasSpan {
1704
1704
  type: "TsUnionType";
1705
1705
  types: TsType[];
@@ -1728,14 +1728,14 @@ export interface TsTypeOperator extends Node, HasSpan {
1728
1728
  op: TsTypeOperatorOp;
1729
1729
  typeAnnotation: TsType;
1730
1730
  }
1731
- export declare type TsTypeOperatorOp = "keyof" | "unique" | "readonly";
1731
+ export type TsTypeOperatorOp = "keyof" | "unique" | "readonly";
1732
1732
  export interface TsIndexedAccessType extends Node, HasSpan {
1733
1733
  type: "TsIndexedAccessType";
1734
1734
  readonly: boolean;
1735
1735
  objectType: TsType;
1736
1736
  indexType: TsType;
1737
1737
  }
1738
- export declare type TruePlusMinus = true | "+" | "-";
1738
+ export type TruePlusMinus = true | "+" | "-";
1739
1739
  export interface TsMappedType extends Node, HasSpan {
1740
1740
  type: "TsMappedType";
1741
1741
  readonly?: TruePlusMinus;
@@ -1748,7 +1748,7 @@ export interface TsLiteralType extends Node, HasSpan {
1748
1748
  type: "TsLiteralType";
1749
1749
  literal: TsLiteral;
1750
1750
  }
1751
- export declare type TsLiteral = NumericLiteral | StringLiteral | BooleanLiteral | BigIntLiteral | TsTemplateLiteralType;
1751
+ export type TsLiteral = NumericLiteral | StringLiteral | BooleanLiteral | BigIntLiteral | TsTemplateLiteralType;
1752
1752
  export interface TsTemplateLiteralType extends Node, HasSpan {
1753
1753
  type: "TemplateLiteral";
1754
1754
  types: TsType[];
@@ -1790,7 +1790,7 @@ export interface TsEnumMember extends Node, HasSpan {
1790
1790
  id: TsEnumMemberId;
1791
1791
  init?: Expression;
1792
1792
  }
1793
- export declare type TsEnumMemberId = Identifier | StringLiteral;
1793
+ export type TsEnumMemberId = Identifier | StringLiteral;
1794
1794
  export interface TsModuleDeclaration extends Node, HasSpan {
1795
1795
  type: "TsModuleDeclaration";
1796
1796
  declare: boolean;
@@ -1801,7 +1801,7 @@ export interface TsModuleDeclaration extends Node, HasSpan {
1801
1801
  /**
1802
1802
  * `namespace A.B { }` is a namespace named `A` with another TsNamespaceDecl as its body.
1803
1803
  */
1804
- export declare type TsNamespaceBody = TsModuleBlock | TsNamespaceDeclaration;
1804
+ export type TsNamespaceBody = TsModuleBlock | TsNamespaceDeclaration;
1805
1805
  export interface TsModuleBlock extends Node, HasSpan {
1806
1806
  type: "TsModuleBlock";
1807
1807
  body: ModuleItem[];
@@ -1813,7 +1813,7 @@ export interface TsNamespaceDeclaration extends Node, HasSpan {
1813
1813
  id: Identifier;
1814
1814
  body: TsNamespaceBody;
1815
1815
  }
1816
- export declare type TsModuleName = Identifier | StringLiteral;
1816
+ export type TsModuleName = Identifier | StringLiteral;
1817
1817
  export interface TsImportEqualsDeclaration extends Node, HasSpan {
1818
1818
  type: "TsImportEqualsDeclaration";
1819
1819
  declare: boolean;
@@ -1822,7 +1822,7 @@ export interface TsImportEqualsDeclaration extends Node, HasSpan {
1822
1822
  id: Identifier;
1823
1823
  moduleRef: TsModuleReference;
1824
1824
  }
1825
- export declare type TsModuleReference = TsEntityName | TsExternalModuleReference;
1825
+ export type TsModuleReference = TsEntityName | TsExternalModuleReference;
1826
1826
  export interface TsExternalModuleReference extends Node, HasSpan {
1827
1827
  type: "TsExternalModuleReference";
1828
1828
  expression: StringLiteral;
@@ -1858,7 +1858,7 @@ export interface TsNonNullExpression extends ExpressionBase {
1858
1858
  type: "TsNonNullExpression";
1859
1859
  expression: Expression;
1860
1860
  }
1861
- export declare type Accessibility = "public" | "protected" | "private";
1861
+ export type Accessibility = "public" | "protected" | "private";
1862
1862
  export interface Invalid extends Node, HasSpan {
1863
1863
  type: "Invalid";
1864
1864
  }