@oxc-project/types 0.68.1 → 0.70.0
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/package.json +1 -1
- package/types.d.ts +12 -195
package/package.json
CHANGED
package/types.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// Auto-generated code, DO NOT EDIT DIRECTLY!
|
|
2
|
-
// To edit this generated file you have to edit `tasks/ast_tools/src/generators/typescript.rs
|
|
2
|
+
// To edit this generated file you have to edit `tasks/ast_tools/src/generators/typescript.rs`.
|
|
3
3
|
|
|
4
4
|
export interface Program extends Span {
|
|
5
5
|
type: 'Program';
|
|
@@ -600,8 +600,10 @@ export type FunctionType =
|
|
|
600
600
|
export interface FormalParameterRest extends Span {
|
|
601
601
|
type: 'RestElement';
|
|
602
602
|
argument: BindingPatternKind;
|
|
603
|
-
|
|
604
|
-
optional
|
|
603
|
+
decorators?: [];
|
|
604
|
+
optional?: boolean;
|
|
605
|
+
typeAnnotation?: TSTypeAnnotation | null;
|
|
606
|
+
value?: null;
|
|
605
607
|
}
|
|
606
608
|
|
|
607
609
|
export type FormalParameter =
|
|
@@ -723,12 +725,12 @@ export type AccessorPropertyType = 'AccessorProperty' | 'TSAbstractAccessorPrope
|
|
|
723
725
|
export interface AccessorProperty extends Span {
|
|
724
726
|
type: AccessorPropertyType;
|
|
725
727
|
key: PropertyKey;
|
|
728
|
+
typeAnnotation?: TSTypeAnnotation | null;
|
|
726
729
|
value: Expression | null;
|
|
727
730
|
computed: boolean;
|
|
728
731
|
static: boolean;
|
|
729
732
|
decorators?: Array<Decorator>;
|
|
730
733
|
definite?: boolean;
|
|
731
|
-
typeAnnotation?: TSTypeAnnotation | null;
|
|
732
734
|
accessibility?: TSAccessibility | null;
|
|
733
735
|
optional?: false;
|
|
734
736
|
override?: boolean;
|
|
@@ -854,12 +856,7 @@ export interface RegExpLiteral extends Span {
|
|
|
854
856
|
type: 'Literal';
|
|
855
857
|
value: RegExp | null;
|
|
856
858
|
raw: string | null;
|
|
857
|
-
regex:
|
|
858
|
-
}
|
|
859
|
-
|
|
860
|
-
export interface RegExp {
|
|
861
|
-
pattern: string;
|
|
862
|
-
flags: string;
|
|
859
|
+
regex: { pattern: string; flags: string };
|
|
863
860
|
}
|
|
864
861
|
|
|
865
862
|
export interface JSXElement extends Span {
|
|
@@ -964,9 +961,9 @@ export interface JSXText extends Span {
|
|
|
964
961
|
export interface TSThisParameter extends Span {
|
|
965
962
|
type: 'Identifier';
|
|
966
963
|
name: 'this';
|
|
967
|
-
typeAnnotation: TSTypeAnnotation | null;
|
|
968
964
|
decorators: [];
|
|
969
965
|
optional: false;
|
|
966
|
+
typeAnnotation: TSTypeAnnotation | null;
|
|
970
967
|
}
|
|
971
968
|
|
|
972
969
|
export interface TSEnumDeclaration extends Span {
|
|
@@ -1097,8 +1094,8 @@ export interface TSTupleType extends Span {
|
|
|
1097
1094
|
|
|
1098
1095
|
export interface TSNamedTupleMember extends Span {
|
|
1099
1096
|
type: 'TSNamedTupleMember';
|
|
1100
|
-
elementType: TSTupleElement;
|
|
1101
1097
|
label: IdentifierName;
|
|
1098
|
+
elementType: TSTupleElement;
|
|
1102
1099
|
optional: boolean;
|
|
1103
1100
|
}
|
|
1104
1101
|
|
|
@@ -1294,9 +1291,9 @@ export interface TSConstructSignatureDeclaration extends Span {
|
|
|
1294
1291
|
export interface TSIndexSignatureName extends Span {
|
|
1295
1292
|
type: 'Identifier';
|
|
1296
1293
|
name: string;
|
|
1297
|
-
typeAnnotation: TSTypeAnnotation;
|
|
1298
1294
|
decorators: [];
|
|
1299
1295
|
optional: false;
|
|
1296
|
+
typeAnnotation: TSTypeAnnotation;
|
|
1300
1297
|
}
|
|
1301
1298
|
|
|
1302
1299
|
export interface TSInterfaceHeritage extends Span {
|
|
@@ -1375,7 +1372,7 @@ export interface TSMappedType extends Span {
|
|
|
1375
1372
|
type: 'TSMappedType';
|
|
1376
1373
|
nameType: TSType | null;
|
|
1377
1374
|
typeAnnotation: TSType | null;
|
|
1378
|
-
optional: TSMappedTypeModifierOperator |
|
|
1375
|
+
optional: TSMappedTypeModifierOperator | false;
|
|
1379
1376
|
readonly: TSMappedTypeModifierOperator | null;
|
|
1380
1377
|
key: TSTypeParameter['name'];
|
|
1381
1378
|
constraint: TSTypeParameter['constraint'];
|
|
@@ -1403,8 +1400,8 @@ export interface TSSatisfiesExpression extends Span {
|
|
|
1403
1400
|
|
|
1404
1401
|
export interface TSTypeAssertion extends Span {
|
|
1405
1402
|
type: 'TSTypeAssertion';
|
|
1406
|
-
expression: Expression;
|
|
1407
1403
|
typeAnnotation: TSType;
|
|
1404
|
+
expression: Expression;
|
|
1408
1405
|
}
|
|
1409
1406
|
|
|
1410
1407
|
export interface TSImportEqualsDeclaration extends Span {
|
|
@@ -1520,166 +1517,6 @@ export interface Span {
|
|
|
1520
1517
|
|
|
1521
1518
|
export type ModuleKind = 'script' | 'module';
|
|
1522
1519
|
|
|
1523
|
-
export interface Pattern extends Span {
|
|
1524
|
-
type: 'Pattern';
|
|
1525
|
-
body: Disjunction;
|
|
1526
|
-
}
|
|
1527
|
-
|
|
1528
|
-
export interface Disjunction extends Span {
|
|
1529
|
-
type: 'Disjunction';
|
|
1530
|
-
body: Array<Alternative>;
|
|
1531
|
-
}
|
|
1532
|
-
|
|
1533
|
-
export interface Alternative extends Span {
|
|
1534
|
-
type: 'Alternative';
|
|
1535
|
-
body: Array<Term>;
|
|
1536
|
-
}
|
|
1537
|
-
|
|
1538
|
-
export type Term =
|
|
1539
|
-
| BoundaryAssertion
|
|
1540
|
-
| LookAroundAssertion
|
|
1541
|
-
| Quantifier
|
|
1542
|
-
| Character
|
|
1543
|
-
| Dot
|
|
1544
|
-
| CharacterClassEscape
|
|
1545
|
-
| UnicodePropertyEscape
|
|
1546
|
-
| CharacterClass
|
|
1547
|
-
| CapturingGroup
|
|
1548
|
-
| IgnoreGroup
|
|
1549
|
-
| IndexedReference
|
|
1550
|
-
| NamedReference;
|
|
1551
|
-
|
|
1552
|
-
export interface BoundaryAssertion extends Span {
|
|
1553
|
-
type: 'BoundaryAssertion';
|
|
1554
|
-
kind: BoundaryAssertionKind;
|
|
1555
|
-
}
|
|
1556
|
-
|
|
1557
|
-
export type BoundaryAssertionKind = 'start' | 'end' | 'boundary' | 'negativeBoundary';
|
|
1558
|
-
|
|
1559
|
-
export interface LookAroundAssertion extends Span {
|
|
1560
|
-
type: 'LookAroundAssertion';
|
|
1561
|
-
kind: LookAroundAssertionKind;
|
|
1562
|
-
body: Disjunction;
|
|
1563
|
-
}
|
|
1564
|
-
|
|
1565
|
-
export type LookAroundAssertionKind = 'lookahead' | 'negativeLookahead' | 'lookbehind' | 'negativeLookbehind';
|
|
1566
|
-
|
|
1567
|
-
export interface Quantifier extends Span {
|
|
1568
|
-
type: 'Quantifier';
|
|
1569
|
-
min: number;
|
|
1570
|
-
max: number | null;
|
|
1571
|
-
greedy: boolean;
|
|
1572
|
-
body: Term;
|
|
1573
|
-
}
|
|
1574
|
-
|
|
1575
|
-
export interface Character extends Span {
|
|
1576
|
-
type: 'Character';
|
|
1577
|
-
kind: CharacterKind;
|
|
1578
|
-
value: number;
|
|
1579
|
-
}
|
|
1580
|
-
|
|
1581
|
-
export type CharacterKind =
|
|
1582
|
-
| 'controlLetter'
|
|
1583
|
-
| 'hexadecimalEscape'
|
|
1584
|
-
| 'identifier'
|
|
1585
|
-
| 'null'
|
|
1586
|
-
| 'octal1'
|
|
1587
|
-
| 'octal2'
|
|
1588
|
-
| 'octal3'
|
|
1589
|
-
| 'singleEscape'
|
|
1590
|
-
| 'symbol'
|
|
1591
|
-
| 'unicodeEscape';
|
|
1592
|
-
|
|
1593
|
-
export interface CharacterClassEscape extends Span {
|
|
1594
|
-
type: 'CharacterClassEscape';
|
|
1595
|
-
kind: CharacterClassEscapeKind;
|
|
1596
|
-
}
|
|
1597
|
-
|
|
1598
|
-
export type CharacterClassEscapeKind = 'd' | 'negativeD' | 's' | 'negativeS' | 'w' | 'negativeW';
|
|
1599
|
-
|
|
1600
|
-
export interface UnicodePropertyEscape extends Span {
|
|
1601
|
-
type: 'UnicodePropertyEscape';
|
|
1602
|
-
negative: boolean;
|
|
1603
|
-
strings: boolean;
|
|
1604
|
-
name: string;
|
|
1605
|
-
value: string | null;
|
|
1606
|
-
}
|
|
1607
|
-
|
|
1608
|
-
export interface Dot extends Span {
|
|
1609
|
-
type: 'Dot';
|
|
1610
|
-
}
|
|
1611
|
-
|
|
1612
|
-
export interface CharacterClass extends Span {
|
|
1613
|
-
type: 'CharacterClass';
|
|
1614
|
-
negative: boolean;
|
|
1615
|
-
strings: boolean;
|
|
1616
|
-
kind: CharacterClassContentsKind;
|
|
1617
|
-
body: Array<CharacterClassContents>;
|
|
1618
|
-
}
|
|
1619
|
-
|
|
1620
|
-
export type CharacterClassContentsKind = 'union' | 'intersection' | 'subtraction';
|
|
1621
|
-
|
|
1622
|
-
export type CharacterClassContents =
|
|
1623
|
-
| CharacterClassRange
|
|
1624
|
-
| CharacterClassEscape
|
|
1625
|
-
| UnicodePropertyEscape
|
|
1626
|
-
| Character
|
|
1627
|
-
| CharacterClass
|
|
1628
|
-
| ClassStringDisjunction;
|
|
1629
|
-
|
|
1630
|
-
export interface CharacterClassRange extends Span {
|
|
1631
|
-
type: 'CharacterClassRange';
|
|
1632
|
-
min: Character;
|
|
1633
|
-
max: Character;
|
|
1634
|
-
}
|
|
1635
|
-
|
|
1636
|
-
export interface ClassStringDisjunction extends Span {
|
|
1637
|
-
type: 'ClassStringDisjunction';
|
|
1638
|
-
strings: boolean;
|
|
1639
|
-
body: Array<ClassString>;
|
|
1640
|
-
}
|
|
1641
|
-
|
|
1642
|
-
export interface ClassString extends Span {
|
|
1643
|
-
type: 'ClassString';
|
|
1644
|
-
strings: boolean;
|
|
1645
|
-
body: Array<Character>;
|
|
1646
|
-
}
|
|
1647
|
-
|
|
1648
|
-
export interface CapturingGroup extends Span {
|
|
1649
|
-
type: 'CapturingGroup';
|
|
1650
|
-
name: string | null;
|
|
1651
|
-
body: Disjunction;
|
|
1652
|
-
}
|
|
1653
|
-
|
|
1654
|
-
export interface IgnoreGroup extends Span {
|
|
1655
|
-
type: 'IgnoreGroup';
|
|
1656
|
-
modifiers: Modifiers | null;
|
|
1657
|
-
body: Disjunction;
|
|
1658
|
-
}
|
|
1659
|
-
|
|
1660
|
-
export interface Modifiers extends Span {
|
|
1661
|
-
type: 'Modifiers';
|
|
1662
|
-
enabling: Modifier | null;
|
|
1663
|
-
disabling: Modifier | null;
|
|
1664
|
-
}
|
|
1665
|
-
|
|
1666
|
-
export interface Modifier {
|
|
1667
|
-
type: 'Modifier';
|
|
1668
|
-
ignoreCase: boolean;
|
|
1669
|
-
multiline: boolean;
|
|
1670
|
-
sticky: boolean;
|
|
1671
|
-
}
|
|
1672
|
-
|
|
1673
|
-
export interface IndexedReference extends Span {
|
|
1674
|
-
type: 'IndexedReference';
|
|
1675
|
-
index: number;
|
|
1676
|
-
}
|
|
1677
|
-
|
|
1678
|
-
export interface NamedReference extends Span {
|
|
1679
|
-
type: 'NamedReference';
|
|
1680
|
-
name: string;
|
|
1681
|
-
}
|
|
1682
|
-
|
|
1683
1520
|
export type Node =
|
|
1684
1521
|
| Program
|
|
1685
1522
|
| IdentifierName
|
|
@@ -1861,24 +1698,4 @@ export type Node =
|
|
|
1861
1698
|
| JSDocNullableType
|
|
1862
1699
|
| JSDocNonNullableType
|
|
1863
1700
|
| JSDocUnknownType
|
|
1864
|
-
| Pattern
|
|
1865
|
-
| Disjunction
|
|
1866
|
-
| Alternative
|
|
1867
|
-
| BoundaryAssertion
|
|
1868
|
-
| LookAroundAssertion
|
|
1869
|
-
| Quantifier
|
|
1870
|
-
| Character
|
|
1871
|
-
| CharacterClassEscape
|
|
1872
|
-
| UnicodePropertyEscape
|
|
1873
|
-
| Dot
|
|
1874
|
-
| CharacterClass
|
|
1875
|
-
| CharacterClassRange
|
|
1876
|
-
| ClassStringDisjunction
|
|
1877
|
-
| ClassString
|
|
1878
|
-
| CapturingGroup
|
|
1879
|
-
| IgnoreGroup
|
|
1880
|
-
| Modifiers
|
|
1881
|
-
| Modifier
|
|
1882
|
-
| IndexedReference
|
|
1883
|
-
| NamedReference
|
|
1884
1701
|
| FormalParameterRest;
|