@schematics/angular 14.0.0-next.7 → 14.0.0-rc.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/app-shell/index.js +4 -8
- package/application/files/src/test.ts.template +1 -1
- package/application/index.js +3 -3
- package/component/files/__name@dasherize@if-flat__/__name@dasherize__.__type@dasherize__.spec.ts.template +1 -1
- package/component/files/__name@dasherize@if-flat__/__name@dasherize__.__type@dasherize__.ts.template +5 -2
- package/component/index.js +9 -14
- package/component/schema.d.ts +4 -0
- package/component/schema.json +6 -0
- package/directive/files/__name@dasherize@if-flat__/__name@dasherize__.directive.ts.template +2 -1
- package/directive/index.js +9 -18
- package/directive/schema.d.ts +4 -0
- package/directive/schema.json +6 -0
- package/e2e/index.js +5 -5
- package/library/files/src/test.ts.template +1 -1
- package/library/index.js +3 -4
- package/migrations/migration-collection.json +5 -0
- package/migrations/update-14/update-libraries-secondary-entrypoints.d.ts +10 -0
- package/migrations/update-14/update-libraries-secondary-entrypoints.js +51 -0
- package/module/index.js +8 -16
- package/package.json +10 -3
- package/pipe/files/__name@dasherize@if-flat__/__name@dasherize__.pipe.ts.template +2 -1
- package/pipe/index.js +8 -17
- package/pipe/schema.d.ts +4 -0
- package/pipe/schema.json +6 -0
- package/service-worker/index.js +4 -8
- package/third_party/github.com/Microsoft/TypeScript/BUILD.bazel +4 -4
- package/third_party/github.com/Microsoft/TypeScript/lib/typescript.d.ts +385 -290
- package/third_party/github.com/Microsoft/TypeScript/lib/typescript.js +11509 -9414
- package/universal/index.js +3 -7
- package/utility/ast-utils.js +26 -26
- package/utility/dependency.d.ts +45 -0
- package/utility/dependency.js +97 -0
- package/utility/find-module.d.ts +1 -0
- package/utility/find-module.js +5 -10
- package/utility/generate-from-files.js +2 -3
- package/utility/index.d.ts +10 -0
- package/utility/index.js +21 -0
- package/utility/json-file.js +1 -7
- package/utility/latest-versions/package.json +4 -3
- package/utility/latest-versions.js +1 -1
- package/utility/ng-ast-utils.js +2 -10
- package/utility/parse-name.js +0 -1
- package/utility/validation.js +1 -3
- package/utility/workspace-models.d.ts +6 -0
- package/utility/workspace-models.js +6 -0
- package/utility/workspace.d.ts +36 -3
- package/utility/workspace.js +70 -34
- package/web-worker/index.js +2 -2
- package/workspace/index.js +1 -2
|
@@ -14,7 +14,7 @@ and limitations under the License.
|
|
|
14
14
|
***************************************************************************** */
|
|
15
15
|
|
|
16
16
|
declare namespace ts {
|
|
17
|
-
const versionMajorMinor = "4.
|
|
17
|
+
const versionMajorMinor = "4.7";
|
|
18
18
|
/** The version of the TypeScript compiler release */
|
|
19
19
|
const version: string;
|
|
20
20
|
/**
|
|
@@ -249,216 +249,219 @@ declare namespace ts {
|
|
|
249
249
|
ModuleKeyword = 141,
|
|
250
250
|
NamespaceKeyword = 142,
|
|
251
251
|
NeverKeyword = 143,
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
252
|
+
OutKeyword = 144,
|
|
253
|
+
ReadonlyKeyword = 145,
|
|
254
|
+
RequireKeyword = 146,
|
|
255
|
+
NumberKeyword = 147,
|
|
256
|
+
ObjectKeyword = 148,
|
|
257
|
+
SetKeyword = 149,
|
|
258
|
+
StringKeyword = 150,
|
|
259
|
+
SymbolKeyword = 151,
|
|
260
|
+
TypeKeyword = 152,
|
|
261
|
+
UndefinedKeyword = 153,
|
|
262
|
+
UniqueKeyword = 154,
|
|
263
|
+
UnknownKeyword = 155,
|
|
264
|
+
FromKeyword = 156,
|
|
265
|
+
GlobalKeyword = 157,
|
|
266
|
+
BigIntKeyword = 158,
|
|
267
|
+
OverrideKeyword = 159,
|
|
268
|
+
OfKeyword = 160,
|
|
269
|
+
QualifiedName = 161,
|
|
270
|
+
ComputedPropertyName = 162,
|
|
271
|
+
TypeParameter = 163,
|
|
272
|
+
Parameter = 164,
|
|
273
|
+
Decorator = 165,
|
|
274
|
+
PropertySignature = 166,
|
|
275
|
+
PropertyDeclaration = 167,
|
|
276
|
+
MethodSignature = 168,
|
|
277
|
+
MethodDeclaration = 169,
|
|
278
|
+
ClassStaticBlockDeclaration = 170,
|
|
279
|
+
Constructor = 171,
|
|
280
|
+
GetAccessor = 172,
|
|
281
|
+
SetAccessor = 173,
|
|
282
|
+
CallSignature = 174,
|
|
283
|
+
ConstructSignature = 175,
|
|
284
|
+
IndexSignature = 176,
|
|
285
|
+
TypePredicate = 177,
|
|
286
|
+
TypeReference = 178,
|
|
287
|
+
FunctionType = 179,
|
|
288
|
+
ConstructorType = 180,
|
|
289
|
+
TypeQuery = 181,
|
|
290
|
+
TypeLiteral = 182,
|
|
291
|
+
ArrayType = 183,
|
|
292
|
+
TupleType = 184,
|
|
293
|
+
OptionalType = 185,
|
|
294
|
+
RestType = 186,
|
|
295
|
+
UnionType = 187,
|
|
296
|
+
IntersectionType = 188,
|
|
297
|
+
ConditionalType = 189,
|
|
298
|
+
InferType = 190,
|
|
299
|
+
ParenthesizedType = 191,
|
|
300
|
+
ThisType = 192,
|
|
301
|
+
TypeOperator = 193,
|
|
302
|
+
IndexedAccessType = 194,
|
|
303
|
+
MappedType = 195,
|
|
304
|
+
LiteralType = 196,
|
|
305
|
+
NamedTupleMember = 197,
|
|
306
|
+
TemplateLiteralType = 198,
|
|
307
|
+
TemplateLiteralTypeSpan = 199,
|
|
308
|
+
ImportType = 200,
|
|
309
|
+
ObjectBindingPattern = 201,
|
|
310
|
+
ArrayBindingPattern = 202,
|
|
311
|
+
BindingElement = 203,
|
|
312
|
+
ArrayLiteralExpression = 204,
|
|
313
|
+
ObjectLiteralExpression = 205,
|
|
314
|
+
PropertyAccessExpression = 206,
|
|
315
|
+
ElementAccessExpression = 207,
|
|
316
|
+
CallExpression = 208,
|
|
317
|
+
NewExpression = 209,
|
|
318
|
+
TaggedTemplateExpression = 210,
|
|
319
|
+
TypeAssertionExpression = 211,
|
|
320
|
+
ParenthesizedExpression = 212,
|
|
321
|
+
FunctionExpression = 213,
|
|
322
|
+
ArrowFunction = 214,
|
|
323
|
+
DeleteExpression = 215,
|
|
324
|
+
TypeOfExpression = 216,
|
|
325
|
+
VoidExpression = 217,
|
|
326
|
+
AwaitExpression = 218,
|
|
327
|
+
PrefixUnaryExpression = 219,
|
|
328
|
+
PostfixUnaryExpression = 220,
|
|
329
|
+
BinaryExpression = 221,
|
|
330
|
+
ConditionalExpression = 222,
|
|
331
|
+
TemplateExpression = 223,
|
|
332
|
+
YieldExpression = 224,
|
|
333
|
+
SpreadElement = 225,
|
|
334
|
+
ClassExpression = 226,
|
|
335
|
+
OmittedExpression = 227,
|
|
336
|
+
ExpressionWithTypeArguments = 228,
|
|
337
|
+
AsExpression = 229,
|
|
338
|
+
NonNullExpression = 230,
|
|
339
|
+
MetaProperty = 231,
|
|
340
|
+
SyntheticExpression = 232,
|
|
341
|
+
TemplateSpan = 233,
|
|
342
|
+
SemicolonClassElement = 234,
|
|
343
|
+
Block = 235,
|
|
344
|
+
EmptyStatement = 236,
|
|
345
|
+
VariableStatement = 237,
|
|
346
|
+
ExpressionStatement = 238,
|
|
347
|
+
IfStatement = 239,
|
|
348
|
+
DoStatement = 240,
|
|
349
|
+
WhileStatement = 241,
|
|
350
|
+
ForStatement = 242,
|
|
351
|
+
ForInStatement = 243,
|
|
352
|
+
ForOfStatement = 244,
|
|
353
|
+
ContinueStatement = 245,
|
|
354
|
+
BreakStatement = 246,
|
|
355
|
+
ReturnStatement = 247,
|
|
356
|
+
WithStatement = 248,
|
|
357
|
+
SwitchStatement = 249,
|
|
358
|
+
LabeledStatement = 250,
|
|
359
|
+
ThrowStatement = 251,
|
|
360
|
+
TryStatement = 252,
|
|
361
|
+
DebuggerStatement = 253,
|
|
362
|
+
VariableDeclaration = 254,
|
|
363
|
+
VariableDeclarationList = 255,
|
|
364
|
+
FunctionDeclaration = 256,
|
|
365
|
+
ClassDeclaration = 257,
|
|
366
|
+
InterfaceDeclaration = 258,
|
|
367
|
+
TypeAliasDeclaration = 259,
|
|
368
|
+
EnumDeclaration = 260,
|
|
369
|
+
ModuleDeclaration = 261,
|
|
370
|
+
ModuleBlock = 262,
|
|
371
|
+
CaseBlock = 263,
|
|
372
|
+
NamespaceExportDeclaration = 264,
|
|
373
|
+
ImportEqualsDeclaration = 265,
|
|
374
|
+
ImportDeclaration = 266,
|
|
375
|
+
ImportClause = 267,
|
|
376
|
+
NamespaceImport = 268,
|
|
377
|
+
NamedImports = 269,
|
|
378
|
+
ImportSpecifier = 270,
|
|
379
|
+
ExportAssignment = 271,
|
|
380
|
+
ExportDeclaration = 272,
|
|
381
|
+
NamedExports = 273,
|
|
382
|
+
NamespaceExport = 274,
|
|
383
|
+
ExportSpecifier = 275,
|
|
384
|
+
MissingDeclaration = 276,
|
|
385
|
+
ExternalModuleReference = 277,
|
|
386
|
+
JsxElement = 278,
|
|
387
|
+
JsxSelfClosingElement = 279,
|
|
388
|
+
JsxOpeningElement = 280,
|
|
389
|
+
JsxClosingElement = 281,
|
|
390
|
+
JsxFragment = 282,
|
|
391
|
+
JsxOpeningFragment = 283,
|
|
392
|
+
JsxClosingFragment = 284,
|
|
393
|
+
JsxAttribute = 285,
|
|
394
|
+
JsxAttributes = 286,
|
|
395
|
+
JsxSpreadAttribute = 287,
|
|
396
|
+
JsxExpression = 288,
|
|
397
|
+
CaseClause = 289,
|
|
398
|
+
DefaultClause = 290,
|
|
399
|
+
HeritageClause = 291,
|
|
400
|
+
CatchClause = 292,
|
|
401
|
+
AssertClause = 293,
|
|
402
|
+
AssertEntry = 294,
|
|
403
|
+
ImportTypeAssertionContainer = 295,
|
|
404
|
+
PropertyAssignment = 296,
|
|
405
|
+
ShorthandPropertyAssignment = 297,
|
|
406
|
+
SpreadAssignment = 298,
|
|
407
|
+
EnumMember = 299,
|
|
408
|
+
UnparsedPrologue = 300,
|
|
409
|
+
UnparsedPrepend = 301,
|
|
410
|
+
UnparsedText = 302,
|
|
411
|
+
UnparsedInternalText = 303,
|
|
412
|
+
UnparsedSyntheticReference = 304,
|
|
413
|
+
SourceFile = 305,
|
|
414
|
+
Bundle = 306,
|
|
415
|
+
UnparsedSource = 307,
|
|
416
|
+
InputFiles = 308,
|
|
417
|
+
JSDocTypeExpression = 309,
|
|
418
|
+
JSDocNameReference = 310,
|
|
419
|
+
JSDocMemberName = 311,
|
|
420
|
+
JSDocAllType = 312,
|
|
421
|
+
JSDocUnknownType = 313,
|
|
422
|
+
JSDocNullableType = 314,
|
|
423
|
+
JSDocNonNullableType = 315,
|
|
424
|
+
JSDocOptionalType = 316,
|
|
425
|
+
JSDocFunctionType = 317,
|
|
426
|
+
JSDocVariadicType = 318,
|
|
427
|
+
JSDocNamepathType = 319,
|
|
428
|
+
/** @deprecated Use SyntaxKind.JSDoc */
|
|
429
|
+
JSDocComment = 320,
|
|
430
|
+
JSDocText = 321,
|
|
431
|
+
JSDocTypeLiteral = 322,
|
|
432
|
+
JSDocSignature = 323,
|
|
433
|
+
JSDocLink = 324,
|
|
434
|
+
JSDocLinkCode = 325,
|
|
435
|
+
JSDocLinkPlain = 326,
|
|
436
|
+
JSDocTag = 327,
|
|
437
|
+
JSDocAugmentsTag = 328,
|
|
438
|
+
JSDocImplementsTag = 329,
|
|
439
|
+
JSDocAuthorTag = 330,
|
|
440
|
+
JSDocDeprecatedTag = 331,
|
|
441
|
+
JSDocClassTag = 332,
|
|
442
|
+
JSDocPublicTag = 333,
|
|
443
|
+
JSDocPrivateTag = 334,
|
|
444
|
+
JSDocProtectedTag = 335,
|
|
445
|
+
JSDocReadonlyTag = 336,
|
|
446
|
+
JSDocOverrideTag = 337,
|
|
447
|
+
JSDocCallbackTag = 338,
|
|
448
|
+
JSDocEnumTag = 339,
|
|
449
|
+
JSDocParameterTag = 340,
|
|
450
|
+
JSDocReturnTag = 341,
|
|
451
|
+
JSDocThisTag = 342,
|
|
452
|
+
JSDocTypeTag = 343,
|
|
453
|
+
JSDocTemplateTag = 344,
|
|
454
|
+
JSDocTypedefTag = 345,
|
|
455
|
+
JSDocSeeTag = 346,
|
|
456
|
+
JSDocPropertyTag = 347,
|
|
457
|
+
SyntaxList = 348,
|
|
458
|
+
NotEmittedStatement = 349,
|
|
459
|
+
PartiallyEmittedExpression = 350,
|
|
460
|
+
CommaListExpression = 351,
|
|
461
|
+
MergeDeclarationMarker = 352,
|
|
462
|
+
EndOfDeclarationMarker = 353,
|
|
463
|
+
SyntheticReferenceExpression = 354,
|
|
464
|
+
Count = 355,
|
|
462
465
|
FirstAssignment = 63,
|
|
463
466
|
LastAssignment = 78,
|
|
464
467
|
FirstCompoundAssignment = 64,
|
|
@@ -466,15 +469,15 @@ declare namespace ts {
|
|
|
466
469
|
FirstReservedWord = 81,
|
|
467
470
|
LastReservedWord = 116,
|
|
468
471
|
FirstKeyword = 81,
|
|
469
|
-
LastKeyword =
|
|
472
|
+
LastKeyword = 160,
|
|
470
473
|
FirstFutureReservedWord = 117,
|
|
471
474
|
LastFutureReservedWord = 125,
|
|
472
|
-
FirstTypeNode =
|
|
473
|
-
LastTypeNode =
|
|
475
|
+
FirstTypeNode = 177,
|
|
476
|
+
LastTypeNode = 200,
|
|
474
477
|
FirstPunctuation = 18,
|
|
475
478
|
LastPunctuation = 78,
|
|
476
479
|
FirstToken = 0,
|
|
477
|
-
LastToken =
|
|
480
|
+
LastToken = 160,
|
|
478
481
|
FirstTriviaToken = 2,
|
|
479
482
|
LastTriviaToken = 7,
|
|
480
483
|
FirstLiteralToken = 8,
|
|
@@ -483,20 +486,21 @@ declare namespace ts {
|
|
|
483
486
|
LastTemplateToken = 17,
|
|
484
487
|
FirstBinaryOperator = 29,
|
|
485
488
|
LastBinaryOperator = 78,
|
|
486
|
-
FirstStatement =
|
|
487
|
-
LastStatement =
|
|
488
|
-
FirstNode =
|
|
489
|
-
FirstJSDocNode =
|
|
490
|
-
LastJSDocNode =
|
|
491
|
-
FirstJSDocTagNode =
|
|
492
|
-
LastJSDocTagNode =
|
|
489
|
+
FirstStatement = 237,
|
|
490
|
+
LastStatement = 253,
|
|
491
|
+
FirstNode = 161,
|
|
492
|
+
FirstJSDocNode = 309,
|
|
493
|
+
LastJSDocNode = 347,
|
|
494
|
+
FirstJSDocTagNode = 327,
|
|
495
|
+
LastJSDocTagNode = 347,
|
|
496
|
+
JSDoc = 320
|
|
493
497
|
}
|
|
494
498
|
export type TriviaSyntaxKind = SyntaxKind.SingleLineCommentTrivia | SyntaxKind.MultiLineCommentTrivia | SyntaxKind.NewLineTrivia | SyntaxKind.WhitespaceTrivia | SyntaxKind.ShebangTrivia | SyntaxKind.ConflictMarkerTrivia;
|
|
495
499
|
export type LiteralSyntaxKind = SyntaxKind.NumericLiteral | SyntaxKind.BigIntLiteral | SyntaxKind.StringLiteral | SyntaxKind.JsxText | SyntaxKind.JsxTextAllWhiteSpaces | SyntaxKind.RegularExpressionLiteral | SyntaxKind.NoSubstitutionTemplateLiteral;
|
|
496
500
|
export type PseudoLiteralSyntaxKind = SyntaxKind.TemplateHead | SyntaxKind.TemplateMiddle | SyntaxKind.TemplateTail;
|
|
497
501
|
export type PunctuationSyntaxKind = SyntaxKind.OpenBraceToken | SyntaxKind.CloseBraceToken | SyntaxKind.OpenParenToken | SyntaxKind.CloseParenToken | SyntaxKind.OpenBracketToken | SyntaxKind.CloseBracketToken | SyntaxKind.DotToken | SyntaxKind.DotDotDotToken | SyntaxKind.SemicolonToken | SyntaxKind.CommaToken | SyntaxKind.QuestionDotToken | SyntaxKind.LessThanToken | SyntaxKind.LessThanSlashToken | SyntaxKind.GreaterThanToken | SyntaxKind.LessThanEqualsToken | SyntaxKind.GreaterThanEqualsToken | SyntaxKind.EqualsEqualsToken | SyntaxKind.ExclamationEqualsToken | SyntaxKind.EqualsEqualsEqualsToken | SyntaxKind.ExclamationEqualsEqualsToken | SyntaxKind.EqualsGreaterThanToken | SyntaxKind.PlusToken | SyntaxKind.MinusToken | SyntaxKind.AsteriskToken | SyntaxKind.AsteriskAsteriskToken | SyntaxKind.SlashToken | SyntaxKind.PercentToken | SyntaxKind.PlusPlusToken | SyntaxKind.MinusMinusToken | SyntaxKind.LessThanLessThanToken | SyntaxKind.GreaterThanGreaterThanToken | SyntaxKind.GreaterThanGreaterThanGreaterThanToken | SyntaxKind.AmpersandToken | SyntaxKind.BarToken | SyntaxKind.CaretToken | SyntaxKind.ExclamationToken | SyntaxKind.TildeToken | SyntaxKind.AmpersandAmpersandToken | SyntaxKind.BarBarToken | SyntaxKind.QuestionQuestionToken | SyntaxKind.QuestionToken | SyntaxKind.ColonToken | SyntaxKind.AtToken | SyntaxKind.BacktickToken | SyntaxKind.HashToken | SyntaxKind.EqualsToken | SyntaxKind.PlusEqualsToken | SyntaxKind.MinusEqualsToken | SyntaxKind.AsteriskEqualsToken | SyntaxKind.AsteriskAsteriskEqualsToken | SyntaxKind.SlashEqualsToken | SyntaxKind.PercentEqualsToken | SyntaxKind.LessThanLessThanEqualsToken | SyntaxKind.GreaterThanGreaterThanEqualsToken | SyntaxKind.GreaterThanGreaterThanGreaterThanEqualsToken | SyntaxKind.AmpersandEqualsToken | SyntaxKind.BarEqualsToken | SyntaxKind.CaretEqualsToken;
|
|
498
|
-
export type KeywordSyntaxKind = SyntaxKind.AbstractKeyword | SyntaxKind.AnyKeyword | SyntaxKind.AsKeyword | SyntaxKind.AssertsKeyword | SyntaxKind.AssertKeyword | SyntaxKind.AsyncKeyword | SyntaxKind.AwaitKeyword | SyntaxKind.BigIntKeyword | SyntaxKind.BooleanKeyword | SyntaxKind.BreakKeyword | SyntaxKind.CaseKeyword | SyntaxKind.CatchKeyword | SyntaxKind.ClassKeyword | SyntaxKind.ConstKeyword | SyntaxKind.ConstructorKeyword | SyntaxKind.ContinueKeyword | SyntaxKind.DebuggerKeyword | SyntaxKind.DeclareKeyword | SyntaxKind.DefaultKeyword | SyntaxKind.DeleteKeyword | SyntaxKind.DoKeyword | SyntaxKind.ElseKeyword | SyntaxKind.EnumKeyword | SyntaxKind.ExportKeyword | SyntaxKind.ExtendsKeyword | SyntaxKind.FalseKeyword | SyntaxKind.FinallyKeyword | SyntaxKind.ForKeyword | SyntaxKind.FromKeyword | SyntaxKind.FunctionKeyword | SyntaxKind.GetKeyword | SyntaxKind.GlobalKeyword | SyntaxKind.IfKeyword | SyntaxKind.ImplementsKeyword | SyntaxKind.ImportKeyword | SyntaxKind.InferKeyword | SyntaxKind.InKeyword | SyntaxKind.InstanceOfKeyword | SyntaxKind.InterfaceKeyword | SyntaxKind.IntrinsicKeyword | SyntaxKind.IsKeyword | SyntaxKind.KeyOfKeyword | SyntaxKind.LetKeyword | SyntaxKind.ModuleKeyword | SyntaxKind.NamespaceKeyword | SyntaxKind.NeverKeyword | SyntaxKind.NewKeyword | SyntaxKind.NullKeyword | SyntaxKind.NumberKeyword | SyntaxKind.ObjectKeyword | SyntaxKind.OfKeyword | SyntaxKind.PackageKeyword | SyntaxKind.PrivateKeyword | SyntaxKind.ProtectedKeyword | SyntaxKind.PublicKeyword | SyntaxKind.ReadonlyKeyword | SyntaxKind.OverrideKeyword | SyntaxKind.RequireKeyword | SyntaxKind.ReturnKeyword | SyntaxKind.SetKeyword | SyntaxKind.StaticKeyword | SyntaxKind.StringKeyword | SyntaxKind.SuperKeyword | SyntaxKind.SwitchKeyword | SyntaxKind.SymbolKeyword | SyntaxKind.ThisKeyword | SyntaxKind.ThrowKeyword | SyntaxKind.TrueKeyword | SyntaxKind.TryKeyword | SyntaxKind.TypeKeyword | SyntaxKind.TypeOfKeyword | SyntaxKind.UndefinedKeyword | SyntaxKind.UniqueKeyword | SyntaxKind.UnknownKeyword | SyntaxKind.VarKeyword | SyntaxKind.VoidKeyword | SyntaxKind.WhileKeyword | SyntaxKind.WithKeyword | SyntaxKind.YieldKeyword;
|
|
499
|
-
export type ModifierSyntaxKind = SyntaxKind.AbstractKeyword | SyntaxKind.AsyncKeyword | SyntaxKind.ConstKeyword | SyntaxKind.DeclareKeyword | SyntaxKind.DefaultKeyword | SyntaxKind.ExportKeyword | SyntaxKind.PrivateKeyword | SyntaxKind.ProtectedKeyword | SyntaxKind.PublicKeyword | SyntaxKind.ReadonlyKeyword | SyntaxKind.OverrideKeyword | SyntaxKind.StaticKeyword;
|
|
502
|
+
export type KeywordSyntaxKind = SyntaxKind.AbstractKeyword | SyntaxKind.AnyKeyword | SyntaxKind.AsKeyword | SyntaxKind.AssertsKeyword | SyntaxKind.AssertKeyword | SyntaxKind.AsyncKeyword | SyntaxKind.AwaitKeyword | SyntaxKind.BigIntKeyword | SyntaxKind.BooleanKeyword | SyntaxKind.BreakKeyword | SyntaxKind.CaseKeyword | SyntaxKind.CatchKeyword | SyntaxKind.ClassKeyword | SyntaxKind.ConstKeyword | SyntaxKind.ConstructorKeyword | SyntaxKind.ContinueKeyword | SyntaxKind.DebuggerKeyword | SyntaxKind.DeclareKeyword | SyntaxKind.DefaultKeyword | SyntaxKind.DeleteKeyword | SyntaxKind.DoKeyword | SyntaxKind.ElseKeyword | SyntaxKind.EnumKeyword | SyntaxKind.ExportKeyword | SyntaxKind.ExtendsKeyword | SyntaxKind.FalseKeyword | SyntaxKind.FinallyKeyword | SyntaxKind.ForKeyword | SyntaxKind.FromKeyword | SyntaxKind.FunctionKeyword | SyntaxKind.GetKeyword | SyntaxKind.GlobalKeyword | SyntaxKind.IfKeyword | SyntaxKind.ImplementsKeyword | SyntaxKind.ImportKeyword | SyntaxKind.InferKeyword | SyntaxKind.InKeyword | SyntaxKind.InstanceOfKeyword | SyntaxKind.InterfaceKeyword | SyntaxKind.IntrinsicKeyword | SyntaxKind.IsKeyword | SyntaxKind.KeyOfKeyword | SyntaxKind.LetKeyword | SyntaxKind.ModuleKeyword | SyntaxKind.NamespaceKeyword | SyntaxKind.NeverKeyword | SyntaxKind.NewKeyword | SyntaxKind.NullKeyword | SyntaxKind.NumberKeyword | SyntaxKind.ObjectKeyword | SyntaxKind.OfKeyword | SyntaxKind.PackageKeyword | SyntaxKind.PrivateKeyword | SyntaxKind.ProtectedKeyword | SyntaxKind.PublicKeyword | SyntaxKind.ReadonlyKeyword | SyntaxKind.OutKeyword | SyntaxKind.OverrideKeyword | SyntaxKind.RequireKeyword | SyntaxKind.ReturnKeyword | SyntaxKind.SetKeyword | SyntaxKind.StaticKeyword | SyntaxKind.StringKeyword | SyntaxKind.SuperKeyword | SyntaxKind.SwitchKeyword | SyntaxKind.SymbolKeyword | SyntaxKind.ThisKeyword | SyntaxKind.ThrowKeyword | SyntaxKind.TrueKeyword | SyntaxKind.TryKeyword | SyntaxKind.TypeKeyword | SyntaxKind.TypeOfKeyword | SyntaxKind.UndefinedKeyword | SyntaxKind.UniqueKeyword | SyntaxKind.UnknownKeyword | SyntaxKind.VarKeyword | SyntaxKind.VoidKeyword | SyntaxKind.WhileKeyword | SyntaxKind.WithKeyword | SyntaxKind.YieldKeyword;
|
|
503
|
+
export type ModifierSyntaxKind = SyntaxKind.AbstractKeyword | SyntaxKind.AsyncKeyword | SyntaxKind.ConstKeyword | SyntaxKind.DeclareKeyword | SyntaxKind.DefaultKeyword | SyntaxKind.ExportKeyword | SyntaxKind.InKeyword | SyntaxKind.PrivateKeyword | SyntaxKind.ProtectedKeyword | SyntaxKind.PublicKeyword | SyntaxKind.ReadonlyKeyword | SyntaxKind.OutKeyword | SyntaxKind.OverrideKeyword | SyntaxKind.StaticKeyword;
|
|
500
504
|
export type KeywordTypeSyntaxKind = SyntaxKind.AnyKeyword | SyntaxKind.BigIntKeyword | SyntaxKind.BooleanKeyword | SyntaxKind.IntrinsicKeyword | SyntaxKind.NeverKeyword | SyntaxKind.NumberKeyword | SyntaxKind.ObjectKeyword | SyntaxKind.StringKeyword | SyntaxKind.SymbolKeyword | SyntaxKind.UndefinedKeyword | SyntaxKind.UnknownKeyword | SyntaxKind.VoidKeyword;
|
|
501
505
|
export type TokenSyntaxKind = SyntaxKind.Unknown | SyntaxKind.EndOfFileToken | TriviaSyntaxKind | LiteralSyntaxKind | PseudoLiteralSyntaxKind | PunctuationSyntaxKind | SyntaxKind.Identifier | KeywordSyntaxKind;
|
|
502
506
|
export type JsxTokenSyntaxKind = SyntaxKind.LessThanSlashToken | SyntaxKind.EndOfFileToken | SyntaxKind.ConflictMarkerTrivia | SyntaxKind.JsxText | SyntaxKind.JsxTextAllWhiteSpaces | SyntaxKind.OpenBraceToken | SyntaxKind.LessThanToken;
|
|
@@ -519,16 +523,17 @@ declare namespace ts {
|
|
|
519
523
|
YieldContext = 8192,
|
|
520
524
|
DecoratorContext = 16384,
|
|
521
525
|
AwaitContext = 32768,
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
526
|
+
DisallowConditionalTypesContext = 65536,
|
|
527
|
+
ThisNodeHasError = 131072,
|
|
528
|
+
JavaScriptFile = 262144,
|
|
529
|
+
ThisNodeOrAnySubNodesHasError = 524288,
|
|
530
|
+
HasAggregatedChildData = 1048576,
|
|
531
|
+
JSDoc = 8388608,
|
|
532
|
+
JsonFile = 67108864,
|
|
528
533
|
BlockScoped = 3,
|
|
529
534
|
ReachabilityCheckFlags = 768,
|
|
530
535
|
ReachabilityAndEmitFlags = 2816,
|
|
531
|
-
ContextFlags =
|
|
536
|
+
ContextFlags = 50720768,
|
|
532
537
|
TypeExcludesFlags = 40960,
|
|
533
538
|
}
|
|
534
539
|
export enum ModifierFlags {
|
|
@@ -547,13 +552,15 @@ declare namespace ts {
|
|
|
547
552
|
HasComputedJSDocModifiers = 4096,
|
|
548
553
|
Deprecated = 8192,
|
|
549
554
|
Override = 16384,
|
|
555
|
+
In = 32768,
|
|
556
|
+
Out = 65536,
|
|
550
557
|
HasComputedFlags = 536870912,
|
|
551
558
|
AccessibilityModifier = 28,
|
|
552
559
|
ParameterPropertyModifier = 16476,
|
|
553
560
|
NonPublicAccessibilityModifier = 24,
|
|
554
|
-
TypeScriptModifier =
|
|
561
|
+
TypeScriptModifier = 116958,
|
|
555
562
|
ExportDefault = 513,
|
|
556
|
-
All =
|
|
563
|
+
All = 125951
|
|
557
564
|
}
|
|
558
565
|
export enum JsxFlags {
|
|
559
566
|
None = 0,
|
|
@@ -572,7 +579,7 @@ declare namespace ts {
|
|
|
572
579
|
}
|
|
573
580
|
export interface JSDocContainer {
|
|
574
581
|
}
|
|
575
|
-
export type HasJSDoc = ParameterDeclaration | CallSignatureDeclaration | ClassStaticBlockDeclaration | ConstructSignatureDeclaration | MethodSignature | PropertySignature | ArrowFunction | ParenthesizedExpression | SpreadAssignment | ShorthandPropertyAssignment | PropertyAssignment | FunctionExpression | EmptyStatement | DebuggerStatement | Block | VariableStatement | ExpressionStatement | IfStatement | DoStatement | WhileStatement | ForStatement | ForInStatement | ForOfStatement | BreakStatement | ContinueStatement | ReturnStatement | WithStatement | SwitchStatement | LabeledStatement | ThrowStatement | TryStatement | FunctionDeclaration | ConstructorDeclaration | MethodDeclaration | VariableDeclaration | PropertyDeclaration | AccessorDeclaration | ClassLikeDeclaration | InterfaceDeclaration | TypeAliasDeclaration | EnumMember | EnumDeclaration | ModuleDeclaration | ImportEqualsDeclaration | ImportDeclaration | NamespaceExportDeclaration | ExportAssignment | IndexSignatureDeclaration | FunctionTypeNode | ConstructorTypeNode | JSDocFunctionType | ExportDeclaration | NamedTupleMember | ExportSpecifier | EndOfFileToken;
|
|
582
|
+
export type HasJSDoc = ParameterDeclaration | CallSignatureDeclaration | ClassStaticBlockDeclaration | ConstructSignatureDeclaration | MethodSignature | PropertySignature | ArrowFunction | ParenthesizedExpression | SpreadAssignment | ShorthandPropertyAssignment | PropertyAssignment | FunctionExpression | EmptyStatement | DebuggerStatement | Block | VariableStatement | ExpressionStatement | IfStatement | DoStatement | WhileStatement | ForStatement | ForInStatement | ForOfStatement | BreakStatement | ContinueStatement | ReturnStatement | WithStatement | SwitchStatement | LabeledStatement | ThrowStatement | TryStatement | FunctionDeclaration | ConstructorDeclaration | MethodDeclaration | VariableDeclaration | PropertyDeclaration | AccessorDeclaration | ClassLikeDeclaration | InterfaceDeclaration | TypeAliasDeclaration | EnumMember | EnumDeclaration | ModuleDeclaration | ImportEqualsDeclaration | ImportDeclaration | NamespaceExportDeclaration | ExportAssignment | IndexSignatureDeclaration | FunctionTypeNode | ConstructorTypeNode | JSDocFunctionType | ExportDeclaration | NamedTupleMember | ExportSpecifier | CaseClause | EndOfFileToken;
|
|
576
583
|
export type HasType = SignatureDeclaration | VariableDeclaration | ParameterDeclaration | PropertySignature | PropertyDeclaration | TypePredicateNode | ParenthesizedTypeNode | TypeOperatorNode | MappedTypeNode | AssertionExpression | TypeAliasDeclaration | JSDocTypeExpression | JSDocNonNullableType | JSDocNullableType | JSDocOptionalType | JSDocVariadicType;
|
|
577
584
|
export type HasTypeArguments = CallExpression | NewExpression | TaggedTemplateExpression | JsxOpeningElement | JsxSelfClosingElement;
|
|
578
585
|
export type HasInitializer = HasExpressionInitializer | ForStatement | ForInStatement | ForOfStatement | JsxAttribute;
|
|
@@ -614,15 +621,17 @@ declare namespace ts {
|
|
|
614
621
|
export type DeclareKeyword = ModifierToken<SyntaxKind.DeclareKeyword>;
|
|
615
622
|
export type DefaultKeyword = ModifierToken<SyntaxKind.DefaultKeyword>;
|
|
616
623
|
export type ExportKeyword = ModifierToken<SyntaxKind.ExportKeyword>;
|
|
624
|
+
export type InKeyword = ModifierToken<SyntaxKind.InKeyword>;
|
|
617
625
|
export type PrivateKeyword = ModifierToken<SyntaxKind.PrivateKeyword>;
|
|
618
626
|
export type ProtectedKeyword = ModifierToken<SyntaxKind.ProtectedKeyword>;
|
|
619
627
|
export type PublicKeyword = ModifierToken<SyntaxKind.PublicKeyword>;
|
|
620
628
|
export type ReadonlyKeyword = ModifierToken<SyntaxKind.ReadonlyKeyword>;
|
|
629
|
+
export type OutKeyword = ModifierToken<SyntaxKind.OutKeyword>;
|
|
621
630
|
export type OverrideKeyword = ModifierToken<SyntaxKind.OverrideKeyword>;
|
|
622
631
|
export type StaticKeyword = ModifierToken<SyntaxKind.StaticKeyword>;
|
|
623
632
|
/** @deprecated Use `ReadonlyKeyword` instead. */
|
|
624
633
|
export type ReadonlyToken = ReadonlyKeyword;
|
|
625
|
-
export type Modifier = AbstractKeyword | AsyncKeyword | ConstKeyword | DeclareKeyword | DefaultKeyword | ExportKeyword | PrivateKeyword | ProtectedKeyword | PublicKeyword | OverrideKeyword | ReadonlyKeyword | StaticKeyword;
|
|
634
|
+
export type Modifier = AbstractKeyword | AsyncKeyword | ConstKeyword | DeclareKeyword | DefaultKeyword | ExportKeyword | InKeyword | PrivateKeyword | ProtectedKeyword | PublicKeyword | OutKeyword | OverrideKeyword | ReadonlyKeyword | StaticKeyword;
|
|
626
635
|
export type AccessibilityModifier = PublicKeyword | PrivateKeyword | ProtectedKeyword;
|
|
627
636
|
export type ParameterPropertyModifier = AccessibilityModifier | ReadonlyKeyword;
|
|
628
637
|
export type ClassMemberModifier = AccessibilityModifier | ReadonlyKeyword | StaticKeyword;
|
|
@@ -866,10 +875,17 @@ declare namespace ts {
|
|
|
866
875
|
export interface KeywordTypeNode<TKind extends KeywordTypeSyntaxKind = KeywordTypeSyntaxKind> extends KeywordToken<TKind>, TypeNode {
|
|
867
876
|
readonly kind: TKind;
|
|
868
877
|
}
|
|
878
|
+
export interface ImportTypeAssertionContainer extends Node {
|
|
879
|
+
readonly kind: SyntaxKind.ImportTypeAssertionContainer;
|
|
880
|
+
readonly parent: ImportTypeNode;
|
|
881
|
+
readonly assertClause: AssertClause;
|
|
882
|
+
readonly multiLine?: boolean;
|
|
883
|
+
}
|
|
869
884
|
export interface ImportTypeNode extends NodeWithTypeArguments {
|
|
870
885
|
readonly kind: SyntaxKind.ImportType;
|
|
871
886
|
readonly isTypeOf: boolean;
|
|
872
887
|
readonly argument: TypeNode;
|
|
888
|
+
readonly assertions?: ImportTypeAssertionContainer;
|
|
873
889
|
readonly qualifier?: EntityName;
|
|
874
890
|
}
|
|
875
891
|
export interface ThisTypeNode extends TypeNode {
|
|
@@ -901,7 +917,7 @@ declare namespace ts {
|
|
|
901
917
|
readonly parameterName: Identifier | ThisTypeNode;
|
|
902
918
|
readonly type?: TypeNode;
|
|
903
919
|
}
|
|
904
|
-
export interface TypeQueryNode extends
|
|
920
|
+
export interface TypeQueryNode extends NodeWithTypeArguments {
|
|
905
921
|
readonly kind: SyntaxKind.TypeQuery;
|
|
906
922
|
readonly exprName: EntityName;
|
|
907
923
|
}
|
|
@@ -1285,9 +1301,8 @@ declare namespace ts {
|
|
|
1285
1301
|
export interface ImportCall extends CallExpression {
|
|
1286
1302
|
readonly expression: ImportExpression;
|
|
1287
1303
|
}
|
|
1288
|
-
export interface ExpressionWithTypeArguments extends NodeWithTypeArguments {
|
|
1304
|
+
export interface ExpressionWithTypeArguments extends MemberExpression, NodeWithTypeArguments {
|
|
1289
1305
|
readonly kind: SyntaxKind.ExpressionWithTypeArguments;
|
|
1290
|
-
readonly parent: HeritageClause | JSDocAugmentsTag | JSDocImplementsTag;
|
|
1291
1306
|
readonly expression: LeftHandSideExpression;
|
|
1292
1307
|
}
|
|
1293
1308
|
export interface NewExpression extends PrimaryExpression, Declaration {
|
|
@@ -1498,7 +1513,7 @@ declare namespace ts {
|
|
|
1498
1513
|
readonly parent: SwitchStatement;
|
|
1499
1514
|
readonly clauses: NodeArray<CaseOrDefaultClause>;
|
|
1500
1515
|
}
|
|
1501
|
-
export interface CaseClause extends Node {
|
|
1516
|
+
export interface CaseClause extends Node, JSDocContainer {
|
|
1502
1517
|
readonly kind: SyntaxKind.CaseClause;
|
|
1503
1518
|
readonly parent: CaseBlock;
|
|
1504
1519
|
readonly expression: Expression;
|
|
@@ -1749,6 +1764,7 @@ declare namespace ts {
|
|
|
1749
1764
|
}
|
|
1750
1765
|
export interface FileReference extends TextRange {
|
|
1751
1766
|
fileName: string;
|
|
1767
|
+
resolutionMode?: SourceFile["impliedNodeFormat"];
|
|
1752
1768
|
}
|
|
1753
1769
|
export interface CheckJsDirective extends TextRange {
|
|
1754
1770
|
enabled: boolean;
|
|
@@ -1790,10 +1806,12 @@ declare namespace ts {
|
|
|
1790
1806
|
export interface JSDocNonNullableType extends JSDocType {
|
|
1791
1807
|
readonly kind: SyntaxKind.JSDocNonNullableType;
|
|
1792
1808
|
readonly type: TypeNode;
|
|
1809
|
+
readonly postfix: boolean;
|
|
1793
1810
|
}
|
|
1794
1811
|
export interface JSDocNullableType extends JSDocType {
|
|
1795
1812
|
readonly kind: SyntaxKind.JSDocNullableType;
|
|
1796
1813
|
readonly type: TypeNode;
|
|
1814
|
+
readonly postfix: boolean;
|
|
1797
1815
|
}
|
|
1798
1816
|
export interface JSDocOptionalType extends JSDocType {
|
|
1799
1817
|
readonly kind: SyntaxKind.JSDocOptionalType;
|
|
@@ -1812,7 +1830,7 @@ declare namespace ts {
|
|
|
1812
1830
|
}
|
|
1813
1831
|
export type JSDocTypeReferencingNode = JSDocVariadicType | JSDocOptionalType | JSDocNullableType | JSDocNonNullableType;
|
|
1814
1832
|
export interface JSDoc extends Node {
|
|
1815
|
-
readonly kind: SyntaxKind.
|
|
1833
|
+
readonly kind: SyntaxKind.JSDoc;
|
|
1816
1834
|
readonly parent: HasJSDoc;
|
|
1817
1835
|
readonly tags?: NodeArray<JSDocTag>;
|
|
1818
1836
|
readonly comment?: string | NodeArray<JSDocComment>;
|
|
@@ -1968,7 +1986,7 @@ declare namespace ts {
|
|
|
1968
1986
|
Label = 12,
|
|
1969
1987
|
Condition = 96
|
|
1970
1988
|
}
|
|
1971
|
-
export type FlowNode = FlowStart | FlowLabel | FlowAssignment |
|
|
1989
|
+
export type FlowNode = FlowStart | FlowLabel | FlowAssignment | FlowCondition | FlowSwitchClause | FlowArrayMutation | FlowCall | FlowReduceLabel;
|
|
1972
1990
|
export interface FlowNodeBase {
|
|
1973
1991
|
flags: FlowFlags;
|
|
1974
1992
|
id?: number;
|
|
@@ -2015,6 +2033,12 @@ declare namespace ts {
|
|
|
2015
2033
|
path: string;
|
|
2016
2034
|
name?: string;
|
|
2017
2035
|
}
|
|
2036
|
+
/**
|
|
2037
|
+
* Subset of properties from SourceFile that are used in multiple utility functions
|
|
2038
|
+
*/
|
|
2039
|
+
export interface SourceFileLike {
|
|
2040
|
+
readonly text: string;
|
|
2041
|
+
}
|
|
2018
2042
|
export interface SourceFile extends Declaration {
|
|
2019
2043
|
readonly kind: SyntaxKind.SourceFile;
|
|
2020
2044
|
readonly statements: NodeArray<Statement>;
|
|
@@ -2074,7 +2098,7 @@ declare namespace ts {
|
|
|
2074
2098
|
readonly prologues: readonly UnparsedPrologue[];
|
|
2075
2099
|
helpers: readonly UnscopedEmitHelper[] | undefined;
|
|
2076
2100
|
referencedFiles: readonly FileReference[];
|
|
2077
|
-
typeReferenceDirectives: readonly
|
|
2101
|
+
typeReferenceDirectives: readonly FileReference[] | undefined;
|
|
2078
2102
|
libReferenceDirectives: readonly FileReference[];
|
|
2079
2103
|
hasNoDefaultLib?: boolean;
|
|
2080
2104
|
sourceMapPath?: string;
|
|
@@ -2654,13 +2678,13 @@ declare namespace ts {
|
|
|
2654
2678
|
ObjectLiteralPatternWithComputedProperties = 512,
|
|
2655
2679
|
ReverseMapped = 1024,
|
|
2656
2680
|
JsxAttributes = 2048,
|
|
2657
|
-
|
|
2658
|
-
|
|
2659
|
-
|
|
2660
|
-
ArrayLiteral = 32768,
|
|
2681
|
+
JSLiteral = 4096,
|
|
2682
|
+
FreshLiteral = 8192,
|
|
2683
|
+
ArrayLiteral = 16384,
|
|
2661
2684
|
ClassOrInterface = 3,
|
|
2662
|
-
ContainsSpread =
|
|
2663
|
-
ObjectRestType =
|
|
2685
|
+
ContainsSpread = 2097152,
|
|
2686
|
+
ObjectRestType = 4194304,
|
|
2687
|
+
InstantiationExpressionType = 8388608,
|
|
2664
2688
|
}
|
|
2665
2689
|
export interface ObjectType extends Type {
|
|
2666
2690
|
objectFlags: ObjectFlags;
|
|
@@ -2871,6 +2895,20 @@ declare namespace ts {
|
|
|
2871
2895
|
Node12 = 3,
|
|
2872
2896
|
NodeNext = 99
|
|
2873
2897
|
}
|
|
2898
|
+
export enum ModuleDetectionKind {
|
|
2899
|
+
/**
|
|
2900
|
+
* Files with imports, exports and/or import.meta are considered modules
|
|
2901
|
+
*/
|
|
2902
|
+
Legacy = 1,
|
|
2903
|
+
/**
|
|
2904
|
+
* Legacy, but also files with jsx under react-jsx or react-jsxdev and esm mode files under moduleResolution: node12+
|
|
2905
|
+
*/
|
|
2906
|
+
Auto = 2,
|
|
2907
|
+
/**
|
|
2908
|
+
* Consider all non-declaration files modules, regardless of present syntax
|
|
2909
|
+
*/
|
|
2910
|
+
Force = 3
|
|
2911
|
+
}
|
|
2874
2912
|
export interface PluginImport {
|
|
2875
2913
|
name: string;
|
|
2876
2914
|
}
|
|
@@ -2942,6 +2980,8 @@ declare namespace ts {
|
|
|
2942
2980
|
maxNodeModuleJsDepth?: number;
|
|
2943
2981
|
module?: ModuleKind;
|
|
2944
2982
|
moduleResolution?: ModuleResolutionKind;
|
|
2983
|
+
moduleSuffixes?: string[];
|
|
2984
|
+
moduleDetection?: ModuleDetectionKind;
|
|
2945
2985
|
newLine?: NewLineKind;
|
|
2946
2986
|
noEmit?: boolean;
|
|
2947
2987
|
noEmitHelpers?: boolean;
|
|
@@ -3127,7 +3167,14 @@ declare namespace ts {
|
|
|
3127
3167
|
realpath?(path: string): string;
|
|
3128
3168
|
getCurrentDirectory?(): string;
|
|
3129
3169
|
getDirectories?(path: string): string[];
|
|
3130
|
-
useCaseSensitiveFileNames?: boolean | (() => boolean);
|
|
3170
|
+
useCaseSensitiveFileNames?: boolean | (() => boolean) | undefined;
|
|
3171
|
+
}
|
|
3172
|
+
/**
|
|
3173
|
+
* Used by services to specify the minimum host area required to set up source files under any compilation settings
|
|
3174
|
+
*/
|
|
3175
|
+
export interface MinimalResolutionCacheHost extends ModuleResolutionHost {
|
|
3176
|
+
getCompilationSettings(): CompilerOptions;
|
|
3177
|
+
getCompilerHost?(): CompilerHost | undefined;
|
|
3131
3178
|
}
|
|
3132
3179
|
/**
|
|
3133
3180
|
* Represents the result of module resolution.
|
|
@@ -3204,8 +3251,8 @@ declare namespace ts {
|
|
|
3204
3251
|
readonly failedLookupLocations: string[];
|
|
3205
3252
|
}
|
|
3206
3253
|
export interface CompilerHost extends ModuleResolutionHost {
|
|
3207
|
-
getSourceFile(fileName: string,
|
|
3208
|
-
getSourceFileByPath?(fileName: string, path: Path,
|
|
3254
|
+
getSourceFile(fileName: string, languageVersionOrOptions: ScriptTarget | CreateSourceFileOptions, onError?: (message: string) => void, shouldCreateNewSourceFile?: boolean): SourceFile | undefined;
|
|
3255
|
+
getSourceFileByPath?(fileName: string, path: Path, languageVersionOrOptions: ScriptTarget | CreateSourceFileOptions, onError?: (message: string) => void, shouldCreateNewSourceFile?: boolean): SourceFile | undefined;
|
|
3209
3256
|
getCancellationToken?(): CancellationToken;
|
|
3210
3257
|
getDefaultLibFileName(options: CompilerOptions): string;
|
|
3211
3258
|
getDefaultLibLocation?(): string;
|
|
@@ -3223,7 +3270,7 @@ declare namespace ts {
|
|
|
3223
3270
|
/**
|
|
3224
3271
|
* This method is a companion for 'resolveModuleNames' and is used to resolve 'types' references to actual type declaration files
|
|
3225
3272
|
*/
|
|
3226
|
-
resolveTypeReferenceDirectives?(typeReferenceDirectiveNames: string[], containingFile: string, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions): (ResolvedTypeReferenceDirective | undefined)[];
|
|
3273
|
+
resolveTypeReferenceDirectives?(typeReferenceDirectiveNames: string[] | readonly FileReference[], containingFile: string, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions, containingFileMode?: SourceFile["impliedNodeFormat"] | undefined): (ResolvedTypeReferenceDirective | undefined)[];
|
|
3227
3274
|
getEnvironmentVariable?(name: string): string | undefined;
|
|
3228
3275
|
createHash?(data: string): string;
|
|
3229
3276
|
getParsedCommandLine?(fileName: string): ParsedCommandLine | undefined;
|
|
@@ -3353,7 +3400,11 @@ declare namespace ts {
|
|
|
3353
3400
|
updateQualifiedName(node: QualifiedName, left: EntityName, right: Identifier): QualifiedName;
|
|
3354
3401
|
createComputedPropertyName(expression: Expression): ComputedPropertyName;
|
|
3355
3402
|
updateComputedPropertyName(node: ComputedPropertyName, expression: Expression): ComputedPropertyName;
|
|
3403
|
+
createTypeParameterDeclaration(modifiers: readonly Modifier[] | undefined, name: string | Identifier, constraint?: TypeNode, defaultType?: TypeNode): TypeParameterDeclaration;
|
|
3404
|
+
/** @deprecated */
|
|
3356
3405
|
createTypeParameterDeclaration(name: string | Identifier, constraint?: TypeNode, defaultType?: TypeNode): TypeParameterDeclaration;
|
|
3406
|
+
updateTypeParameterDeclaration(node: TypeParameterDeclaration, modifiers: readonly Modifier[] | undefined, name: Identifier, constraint: TypeNode | undefined, defaultType: TypeNode | undefined): TypeParameterDeclaration;
|
|
3407
|
+
/** @deprecated */
|
|
3357
3408
|
updateTypeParameterDeclaration(node: TypeParameterDeclaration, name: Identifier, constraint: TypeNode | undefined, defaultType: TypeNode | undefined): TypeParameterDeclaration;
|
|
3358
3409
|
createParameterDeclaration(decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, dotDotDotToken: DotDotDotToken | undefined, name: string | BindingName, questionToken?: QuestionToken, type?: TypeNode, initializer?: Expression): ParameterDeclaration;
|
|
3359
3410
|
updateParameterDeclaration(node: ParameterDeclaration, decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, dotDotDotToken: DotDotDotToken | undefined, name: string | BindingName, questionToken: QuestionToken | undefined, type: TypeNode | undefined, initializer: Expression | undefined): ParameterDeclaration;
|
|
@@ -3396,8 +3447,8 @@ declare namespace ts {
|
|
|
3396
3447
|
updateConstructorTypeNode(node: ConstructorTypeNode, modifiers: readonly Modifier[] | undefined, typeParameters: NodeArray<TypeParameterDeclaration> | undefined, parameters: NodeArray<ParameterDeclaration>, type: TypeNode): ConstructorTypeNode;
|
|
3397
3448
|
/** @deprecated */
|
|
3398
3449
|
updateConstructorTypeNode(node: ConstructorTypeNode, typeParameters: NodeArray<TypeParameterDeclaration> | undefined, parameters: NodeArray<ParameterDeclaration>, type: TypeNode): ConstructorTypeNode;
|
|
3399
|
-
createTypeQueryNode(exprName: EntityName): TypeQueryNode;
|
|
3400
|
-
updateTypeQueryNode(node: TypeQueryNode, exprName: EntityName): TypeQueryNode;
|
|
3450
|
+
createTypeQueryNode(exprName: EntityName, typeArguments?: readonly TypeNode[]): TypeQueryNode;
|
|
3451
|
+
updateTypeQueryNode(node: TypeQueryNode, exprName: EntityName, typeArguments?: readonly TypeNode[]): TypeQueryNode;
|
|
3401
3452
|
createTypeLiteralNode(members: readonly TypeElement[] | undefined): TypeLiteralNode;
|
|
3402
3453
|
updateTypeLiteralNode(node: TypeLiteralNode, members: NodeArray<TypeElement>): TypeLiteralNode;
|
|
3403
3454
|
createArrayTypeNode(elementType: TypeNode): ArrayTypeNode;
|
|
@@ -3419,7 +3470,9 @@ declare namespace ts {
|
|
|
3419
3470
|
createInferTypeNode(typeParameter: TypeParameterDeclaration): InferTypeNode;
|
|
3420
3471
|
updateInferTypeNode(node: InferTypeNode, typeParameter: TypeParameterDeclaration): InferTypeNode;
|
|
3421
3472
|
createImportTypeNode(argument: TypeNode, qualifier?: EntityName, typeArguments?: readonly TypeNode[], isTypeOf?: boolean): ImportTypeNode;
|
|
3473
|
+
createImportTypeNode(argument: TypeNode, assertions?: ImportTypeAssertionContainer, qualifier?: EntityName, typeArguments?: readonly TypeNode[], isTypeOf?: boolean): ImportTypeNode;
|
|
3422
3474
|
updateImportTypeNode(node: ImportTypeNode, argument: TypeNode, qualifier: EntityName | undefined, typeArguments: readonly TypeNode[] | undefined, isTypeOf?: boolean): ImportTypeNode;
|
|
3475
|
+
updateImportTypeNode(node: ImportTypeNode, argument: TypeNode, assertions: ImportTypeAssertionContainer | undefined, qualifier: EntityName | undefined, typeArguments: readonly TypeNode[] | undefined, isTypeOf?: boolean): ImportTypeNode;
|
|
3423
3476
|
createParenthesizedType(type: TypeNode): ParenthesizedTypeNode;
|
|
3424
3477
|
updateParenthesizedType(node: ParenthesizedTypeNode, type: TypeNode): ParenthesizedTypeNode;
|
|
3425
3478
|
createThisTypeNode(): ThisTypeNode;
|
|
@@ -3582,6 +3635,8 @@ declare namespace ts {
|
|
|
3582
3635
|
updateAssertClause(node: AssertClause, elements: NodeArray<AssertEntry>, multiLine?: boolean): AssertClause;
|
|
3583
3636
|
createAssertEntry(name: AssertionKey, value: Expression): AssertEntry;
|
|
3584
3637
|
updateAssertEntry(node: AssertEntry, name: AssertionKey, value: Expression): AssertEntry;
|
|
3638
|
+
createImportTypeAssertionContainer(clause: AssertClause, multiLine?: boolean): ImportTypeAssertionContainer;
|
|
3639
|
+
updateImportTypeAssertionContainer(node: ImportTypeAssertionContainer, clause: AssertClause, multiLine?: boolean): ImportTypeAssertionContainer;
|
|
3585
3640
|
createNamespaceImport(name: Identifier): NamespaceImport;
|
|
3586
3641
|
updateNamespaceImport(node: NamespaceImport, name: Identifier): NamespaceImport;
|
|
3587
3642
|
createNamespaceExport(name: Identifier): NamespaceExport;
|
|
@@ -3602,9 +3657,9 @@ declare namespace ts {
|
|
|
3602
3657
|
updateExternalModuleReference(node: ExternalModuleReference, expression: Expression): ExternalModuleReference;
|
|
3603
3658
|
createJSDocAllType(): JSDocAllType;
|
|
3604
3659
|
createJSDocUnknownType(): JSDocUnknownType;
|
|
3605
|
-
createJSDocNonNullableType(type: TypeNode): JSDocNonNullableType;
|
|
3660
|
+
createJSDocNonNullableType(type: TypeNode, postfix?: boolean): JSDocNonNullableType;
|
|
3606
3661
|
updateJSDocNonNullableType(node: JSDocNonNullableType, type: TypeNode): JSDocNonNullableType;
|
|
3607
|
-
createJSDocNullableType(type: TypeNode): JSDocNullableType;
|
|
3662
|
+
createJSDocNullableType(type: TypeNode, postfix?: boolean): JSDocNullableType;
|
|
3608
3663
|
updateJSDocNullableType(node: JSDocNullableType, type: TypeNode): JSDocNullableType;
|
|
3609
3664
|
createJSDocOptionalType(type: TypeNode): JSDocOptionalType;
|
|
3610
3665
|
updateJSDocOptionalType(node: JSDocOptionalType, type: TypeNode): JSDocOptionalType;
|
|
@@ -4048,6 +4103,8 @@ declare namespace ts {
|
|
|
4048
4103
|
readonly includeAutomaticOptionalChainCompletions?: boolean;
|
|
4049
4104
|
readonly includeCompletionsWithInsertText?: boolean;
|
|
4050
4105
|
readonly includeCompletionsWithClassMemberSnippets?: boolean;
|
|
4106
|
+
readonly includeCompletionsWithObjectLiteralMethodSnippets?: boolean;
|
|
4107
|
+
readonly useLabelDetailsInCompletionEntries?: boolean;
|
|
4051
4108
|
readonly allowIncompleteCompletions?: boolean;
|
|
4052
4109
|
readonly importModuleSpecifierPreference?: "shortest" | "project-relative" | "relative" | "non-relative";
|
|
4053
4110
|
/** Determines whether we import `foo/index.ts` as "foo", "foo/index", or "foo/index.js" */
|
|
@@ -4057,6 +4114,13 @@ declare namespace ts {
|
|
|
4057
4114
|
readonly includePackageJsonAutoImports?: "auto" | "on" | "off";
|
|
4058
4115
|
readonly provideRefactorNotApplicableReason?: boolean;
|
|
4059
4116
|
readonly jsxAttributeCompletionStyle?: "auto" | "braces" | "none";
|
|
4117
|
+
readonly includeInlayParameterNameHints?: "none" | "literals" | "all";
|
|
4118
|
+
readonly includeInlayParameterNameHintsWhenArgumentMatchesName?: boolean;
|
|
4119
|
+
readonly includeInlayFunctionParameterTypeHints?: boolean;
|
|
4120
|
+
readonly includeInlayVariableTypeHints?: boolean;
|
|
4121
|
+
readonly includeInlayPropertyDeclarationTypeHints?: boolean;
|
|
4122
|
+
readonly includeInlayFunctionLikeReturnTypeHints?: boolean;
|
|
4123
|
+
readonly includeInlayEnumMemberValueHints?: boolean;
|
|
4060
4124
|
}
|
|
4061
4125
|
/** Represents a bigint literal value without requiring bigint support */
|
|
4062
4126
|
export interface PseudoBigInt {
|
|
@@ -4748,7 +4812,22 @@ declare namespace ts {
|
|
|
4748
4812
|
* that they appear in the source code. The language service depends on this property to locate nodes by position.
|
|
4749
4813
|
*/
|
|
4750
4814
|
export function forEachChild<T>(node: Node, cbNode: (node: Node) => T | undefined, cbNodes?: (nodes: NodeArray<Node>) => T | undefined): T | undefined;
|
|
4751
|
-
export
|
|
4815
|
+
export interface CreateSourceFileOptions {
|
|
4816
|
+
languageVersion: ScriptTarget;
|
|
4817
|
+
/**
|
|
4818
|
+
* Controls the format the file is detected as - this can be derived from only the path
|
|
4819
|
+
* and files on disk, but needs to be done with a module resolution cache in scope to be performant.
|
|
4820
|
+
* This is usually `undefined` for compilations that do not have `moduleResolution` values of `node12` or `nodenext`.
|
|
4821
|
+
*/
|
|
4822
|
+
impliedNodeFormat?: ModuleKind.ESNext | ModuleKind.CommonJS;
|
|
4823
|
+
/**
|
|
4824
|
+
* Controls how module-y-ness is set for the given file. Usually the result of calling
|
|
4825
|
+
* `getSetExternalModuleIndicator` on a valid `CompilerOptions` object. If not present, the default
|
|
4826
|
+
* check specified by `isFileProbablyExternalModule` will be used to set the field.
|
|
4827
|
+
*/
|
|
4828
|
+
setExternalModuleIndicator?: (file: SourceFile) => void;
|
|
4829
|
+
}
|
|
4830
|
+
export function createSourceFile(fileName: string, sourceText: string, languageVersionOrOptions: ScriptTarget | CreateSourceFileOptions, setParentNodes?: boolean, scriptKind?: ScriptKind): SourceFile;
|
|
4752
4831
|
export function parseIsolatedEntityName(text: string, languageVersion: ScriptTarget): EntityName | undefined;
|
|
4753
4832
|
/**
|
|
4754
4833
|
* Parse json text into SyntaxTree and return node and parse errors if any
|
|
@@ -4855,7 +4934,7 @@ declare namespace ts {
|
|
|
4855
4934
|
* This is possible in case if resolution is performed for directives specified via 'types' parameter. In this case initial path for secondary lookups
|
|
4856
4935
|
* is assumed to be the same as root directory of the project.
|
|
4857
4936
|
*/
|
|
4858
|
-
export function resolveTypeReferenceDirective(typeReferenceDirectiveName: string, containingFile: string | undefined, options: CompilerOptions, host: ModuleResolutionHost, redirectedReference?: ResolvedProjectReference, cache?: TypeReferenceDirectiveResolutionCache): ResolvedTypeReferenceDirectiveWithFailedLookupLocations;
|
|
4937
|
+
export function resolveTypeReferenceDirective(typeReferenceDirectiveName: string, containingFile: string | undefined, options: CompilerOptions, host: ModuleResolutionHost, redirectedReference?: ResolvedProjectReference, cache?: TypeReferenceDirectiveResolutionCache, resolutionMode?: SourceFile["impliedNodeFormat"]): ResolvedTypeReferenceDirectiveWithFailedLookupLocations;
|
|
4859
4938
|
/**
|
|
4860
4939
|
* Given a set of options, returns the set of type directive names
|
|
4861
4940
|
* that should be included for this program automatically.
|
|
@@ -5276,7 +5355,7 @@ declare namespace ts {
|
|
|
5276
5355
|
/** If provided, used to resolve the module names, otherwise typescript's default module resolution */
|
|
5277
5356
|
resolveModuleNames?(moduleNames: string[], containingFile: string, reusedNames: string[] | undefined, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions, containingSourceFile?: SourceFile): (ResolvedModule | undefined)[];
|
|
5278
5357
|
/** If provided, used to resolve type reference directives, otherwise typescript's default resolution */
|
|
5279
|
-
resolveTypeReferenceDirectives?(typeReferenceDirectiveNames: string[], containingFile: string, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions): (ResolvedTypeReferenceDirective | undefined)[];
|
|
5358
|
+
resolveTypeReferenceDirectives?(typeReferenceDirectiveNames: string[] | readonly FileReference[], containingFile: string, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions, containingFileMode?: SourceFile["impliedNodeFormat"] | undefined): (ResolvedTypeReferenceDirective | undefined)[];
|
|
5280
5359
|
}
|
|
5281
5360
|
interface WatchCompilerHost<T extends BuilderProgram> extends ProgramHost<T>, WatchHost {
|
|
5282
5361
|
/** Instead of using output d.ts file from project reference, use its source file */
|
|
@@ -5648,7 +5727,7 @@ declare namespace ts {
|
|
|
5648
5727
|
set(response: CompletionInfo): void;
|
|
5649
5728
|
clear(): void;
|
|
5650
5729
|
}
|
|
5651
|
-
interface LanguageServiceHost extends GetEffectiveTypeRootsHost {
|
|
5730
|
+
interface LanguageServiceHost extends GetEffectiveTypeRootsHost, MinimalResolutionCacheHost {
|
|
5652
5731
|
getCompilationSettings(): CompilerOptions;
|
|
5653
5732
|
getNewLine?(): string;
|
|
5654
5733
|
getProjectVersion?(): string;
|
|
@@ -5666,13 +5745,13 @@ declare namespace ts {
|
|
|
5666
5745
|
error?(s: string): void;
|
|
5667
5746
|
useCaseSensitiveFileNames?(): boolean;
|
|
5668
5747
|
readDirectory?(path: string, extensions?: readonly string[], exclude?: readonly string[], include?: readonly string[], depth?: number): string[];
|
|
5669
|
-
readFile?(path: string, encoding?: string): string | undefined;
|
|
5670
5748
|
realpath?(path: string): string;
|
|
5671
|
-
|
|
5749
|
+
readFile(path: string, encoding?: string): string | undefined;
|
|
5750
|
+
fileExists(path: string): boolean;
|
|
5672
5751
|
getTypeRootsVersion?(): number;
|
|
5673
5752
|
resolveModuleNames?(moduleNames: string[], containingFile: string, reusedNames: string[] | undefined, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions, containingSourceFile?: SourceFile): (ResolvedModule | undefined)[];
|
|
5674
5753
|
getResolvedModuleWithFailedLookupLocationsFromCache?(modulename: string, containingFile: string, resolutionMode?: ModuleKind.CommonJS | ModuleKind.ESNext): ResolvedModuleWithFailedLookupLocations | undefined;
|
|
5675
|
-
resolveTypeReferenceDirectives?(typeDirectiveNames: string[], containingFile: string, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions): (ResolvedTypeReferenceDirective | undefined)[];
|
|
5754
|
+
resolveTypeReferenceDirectives?(typeDirectiveNames: string[] | FileReference[], containingFile: string, redirectedReference: ResolvedProjectReference | undefined, options: CompilerOptions, containingFileMode?: SourceFile["impliedNodeFormat"] | undefined): (ResolvedTypeReferenceDirective | undefined)[];
|
|
5676
5755
|
getDirectories?(directoryName: string): string[];
|
|
5677
5756
|
/**
|
|
5678
5757
|
* Gets a set of custom transformers to use during emit.
|
|
@@ -5881,15 +5960,6 @@ declare namespace ts {
|
|
|
5881
5960
|
/** @deprecated Use includeCompletionsWithInsertText */
|
|
5882
5961
|
includeInsertTextCompletions?: boolean;
|
|
5883
5962
|
}
|
|
5884
|
-
interface InlayHintsOptions extends UserPreferences {
|
|
5885
|
-
readonly includeInlayParameterNameHints?: "none" | "literals" | "all";
|
|
5886
|
-
readonly includeInlayParameterNameHintsWhenArgumentMatchesName?: boolean;
|
|
5887
|
-
readonly includeInlayFunctionParameterTypeHints?: boolean;
|
|
5888
|
-
readonly includeInlayVariableTypeHints?: boolean;
|
|
5889
|
-
readonly includeInlayPropertyDeclarationTypeHints?: boolean;
|
|
5890
|
-
readonly includeInlayFunctionLikeReturnTypeHints?: boolean;
|
|
5891
|
-
readonly includeInlayEnumMemberValueHints?: boolean;
|
|
5892
|
-
}
|
|
5893
5963
|
type SignatureHelpTriggerCharacter = "," | "(" | "<";
|
|
5894
5964
|
type SignatureHelpRetriggerCharacter = SignatureHelpTriggerCharacter | ")";
|
|
5895
5965
|
interface SignatureHelpItemsOptions {
|
|
@@ -6139,7 +6209,6 @@ declare namespace ts {
|
|
|
6139
6209
|
}
|
|
6140
6210
|
interface ReferenceEntry extends DocumentSpan {
|
|
6141
6211
|
isWriteAccess: boolean;
|
|
6142
|
-
isDefinition: boolean;
|
|
6143
6212
|
isInString?: true;
|
|
6144
6213
|
}
|
|
6145
6214
|
interface ImplementationLocation extends DocumentSpan {
|
|
@@ -6253,7 +6322,10 @@ declare namespace ts {
|
|
|
6253
6322
|
}
|
|
6254
6323
|
interface ReferencedSymbol {
|
|
6255
6324
|
definition: ReferencedSymbolDefinitionInfo;
|
|
6256
|
-
references:
|
|
6325
|
+
references: ReferencedSymbolEntry[];
|
|
6326
|
+
}
|
|
6327
|
+
interface ReferencedSymbolEntry extends ReferenceEntry {
|
|
6328
|
+
isDefinition?: boolean;
|
|
6257
6329
|
}
|
|
6258
6330
|
enum SymbolDisplayPartKind {
|
|
6259
6331
|
aliasName = 0,
|
|
@@ -6420,6 +6492,7 @@ declare namespace ts {
|
|
|
6420
6492
|
hasAction?: true;
|
|
6421
6493
|
source?: string;
|
|
6422
6494
|
sourceDisplay?: SymbolDisplayPart[];
|
|
6495
|
+
labelDetails?: CompletionEntryLabelDetails;
|
|
6423
6496
|
isRecommended?: true;
|
|
6424
6497
|
isFromUncheckedFile?: true;
|
|
6425
6498
|
isPackageJsonImport?: true;
|
|
@@ -6434,6 +6507,10 @@ declare namespace ts {
|
|
|
6434
6507
|
*/
|
|
6435
6508
|
data?: CompletionEntryData;
|
|
6436
6509
|
}
|
|
6510
|
+
interface CompletionEntryLabelDetails {
|
|
6511
|
+
detail?: string;
|
|
6512
|
+
description?: string;
|
|
6513
|
+
}
|
|
6437
6514
|
interface CompletionEntryDetails {
|
|
6438
6515
|
name: string;
|
|
6439
6516
|
kind: ScriptElementKind;
|
|
@@ -6693,7 +6770,7 @@ declare namespace ts {
|
|
|
6693
6770
|
cancellationToken: CancellationToken;
|
|
6694
6771
|
host: LanguageServiceHost;
|
|
6695
6772
|
span: TextSpan;
|
|
6696
|
-
preferences:
|
|
6773
|
+
preferences: UserPreferences;
|
|
6697
6774
|
}
|
|
6698
6775
|
}
|
|
6699
6776
|
declare namespace ts {
|
|
@@ -6729,30 +6806,36 @@ declare namespace ts {
|
|
|
6729
6806
|
* the SourceFile if was not found in the registry.
|
|
6730
6807
|
*
|
|
6731
6808
|
* @param fileName The name of the file requested
|
|
6732
|
-
* @param
|
|
6809
|
+
* @param compilationSettingsOrHost Some compilation settings like target affects the
|
|
6733
6810
|
* shape of a the resulting SourceFile. This allows the DocumentRegistry to store
|
|
6734
|
-
* multiple copies of the same file for different compilation settings.
|
|
6811
|
+
* multiple copies of the same file for different compilation settings. A minimal
|
|
6812
|
+
* resolution cache is needed to fully define a source file's shape when
|
|
6813
|
+
* the compilation settings include `module: node12`+, so providing a cache host
|
|
6814
|
+
* object should be preferred. A common host is a language service `ConfiguredProject`.
|
|
6735
6815
|
* @param scriptSnapshot Text of the file. Only used if the file was not found
|
|
6736
6816
|
* in the registry and a new one was created.
|
|
6737
6817
|
* @param version Current version of the file. Only used if the file was not found
|
|
6738
6818
|
* in the registry and a new one was created.
|
|
6739
6819
|
*/
|
|
6740
|
-
acquireDocument(fileName: string,
|
|
6741
|
-
acquireDocumentWithKey(fileName: string, path: Path,
|
|
6820
|
+
acquireDocument(fileName: string, compilationSettingsOrHost: CompilerOptions | MinimalResolutionCacheHost, scriptSnapshot: IScriptSnapshot, version: string, scriptKind?: ScriptKind): SourceFile;
|
|
6821
|
+
acquireDocumentWithKey(fileName: string, path: Path, compilationSettingsOrHost: CompilerOptions | MinimalResolutionCacheHost, key: DocumentRegistryBucketKey, scriptSnapshot: IScriptSnapshot, version: string, scriptKind?: ScriptKind): SourceFile;
|
|
6742
6822
|
/**
|
|
6743
6823
|
* Request an updated version of an already existing SourceFile with a given fileName
|
|
6744
6824
|
* and compilationSettings. The update will in-turn call updateLanguageServiceSourceFile
|
|
6745
6825
|
* to get an updated SourceFile.
|
|
6746
6826
|
*
|
|
6747
6827
|
* @param fileName The name of the file requested
|
|
6748
|
-
* @param
|
|
6828
|
+
* @param compilationSettingsOrHost Some compilation settings like target affects the
|
|
6749
6829
|
* shape of a the resulting SourceFile. This allows the DocumentRegistry to store
|
|
6750
|
-
* multiple copies of the same file for different compilation settings.
|
|
6830
|
+
* multiple copies of the same file for different compilation settings. A minimal
|
|
6831
|
+
* resolution cache is needed to fully define a source file's shape when
|
|
6832
|
+
* the compilation settings include `module: node12`+, so providing a cache host
|
|
6833
|
+
* object should be preferred. A common host is a language service `ConfiguredProject`.
|
|
6751
6834
|
* @param scriptSnapshot Text of the file.
|
|
6752
6835
|
* @param version Current version of the file.
|
|
6753
6836
|
*/
|
|
6754
|
-
updateDocument(fileName: string,
|
|
6755
|
-
updateDocumentWithKey(fileName: string, path: Path,
|
|
6837
|
+
updateDocument(fileName: string, compilationSettingsOrHost: CompilerOptions | MinimalResolutionCacheHost, scriptSnapshot: IScriptSnapshot, version: string, scriptKind?: ScriptKind): SourceFile;
|
|
6838
|
+
updateDocumentWithKey(fileName: string, path: Path, compilationSettingsOrHost: CompilerOptions | MinimalResolutionCacheHost, key: DocumentRegistryBucketKey, scriptSnapshot: IScriptSnapshot, version: string, scriptKind?: ScriptKind): SourceFile;
|
|
6756
6839
|
getKeyForCompilationSettings(settings: CompilerOptions): DocumentRegistryBucketKey;
|
|
6757
6840
|
/**
|
|
6758
6841
|
* Informs the DocumentRegistry that a file is not needed any longer.
|
|
@@ -6814,7 +6897,7 @@ declare namespace ts {
|
|
|
6814
6897
|
function displayPartsToString(displayParts: SymbolDisplayPart[] | undefined): string;
|
|
6815
6898
|
function getDefaultCompilerOptions(): CompilerOptions;
|
|
6816
6899
|
function getSupportedCodeFixes(): string[];
|
|
6817
|
-
function createLanguageServiceSourceFile(fileName: string, scriptSnapshot: IScriptSnapshot,
|
|
6900
|
+
function createLanguageServiceSourceFile(fileName: string, scriptSnapshot: IScriptSnapshot, scriptTargetOrOptions: ScriptTarget | CreateSourceFileOptions, version: string, setNodeParents: boolean, scriptKind?: ScriptKind): SourceFile;
|
|
6818
6901
|
function updateLanguageServiceSourceFile(sourceFile: SourceFile, scriptSnapshot: IScriptSnapshot, version: string, textChangeRange: TextChangeRange | undefined, aggressiveChecks?: boolean): SourceFile;
|
|
6819
6902
|
function createLanguageService(host: LanguageServiceHost, documentRegistry?: DocumentRegistry, syntaxOnlyOrLanguageServiceMode?: boolean | LanguageServiceMode): LanguageService;
|
|
6820
6903
|
/**
|
|
@@ -6878,9 +6961,15 @@ declare namespace ts {
|
|
|
6878
6961
|
/** @deprecated Use `factory.updateComputedPropertyName` or the factory supplied by your transformation context instead. */
|
|
6879
6962
|
const updateComputedPropertyName: (node: ComputedPropertyName, expression: Expression) => ComputedPropertyName;
|
|
6880
6963
|
/** @deprecated Use `factory.createTypeParameterDeclaration` or the factory supplied by your transformation context instead. */
|
|
6881
|
-
const createTypeParameterDeclaration:
|
|
6964
|
+
const createTypeParameterDeclaration: {
|
|
6965
|
+
(modifiers: readonly Modifier[] | undefined, name: string | Identifier, constraint?: TypeNode | undefined, defaultType?: TypeNode | undefined): TypeParameterDeclaration;
|
|
6966
|
+
(name: string | Identifier, constraint?: TypeNode | undefined, defaultType?: TypeNode | undefined): TypeParameterDeclaration;
|
|
6967
|
+
};
|
|
6882
6968
|
/** @deprecated Use `factory.updateTypeParameterDeclaration` or the factory supplied by your transformation context instead. */
|
|
6883
|
-
const updateTypeParameterDeclaration:
|
|
6969
|
+
const updateTypeParameterDeclaration: {
|
|
6970
|
+
(node: TypeParameterDeclaration, modifiers: readonly Modifier[] | undefined, name: Identifier, constraint: TypeNode | undefined, defaultType: TypeNode | undefined): TypeParameterDeclaration;
|
|
6971
|
+
(node: TypeParameterDeclaration, name: Identifier, constraint: TypeNode | undefined, defaultType: TypeNode | undefined): TypeParameterDeclaration;
|
|
6972
|
+
};
|
|
6884
6973
|
/** @deprecated Use `factory.createParameterDeclaration` or the factory supplied by your transformation context instead. */
|
|
6885
6974
|
const createParameter: (decorators: readonly Decorator[] | undefined, modifiers: readonly Modifier[] | undefined, dotDotDotToken: DotDotDotToken | undefined, name: string | BindingName, questionToken?: QuestionToken | undefined, type?: TypeNode | undefined, initializer?: Expression | undefined) => ParameterDeclaration;
|
|
6886
6975
|
/** @deprecated Use `factory.updateParameterDeclaration` or the factory supplied by your transformation context instead. */
|
|
@@ -6938,9 +7027,9 @@ declare namespace ts {
|
|
|
6938
7027
|
/** @deprecated Use `factory.updateConstructorTypeNode` or the factory supplied by your transformation context instead. */
|
|
6939
7028
|
const updateConstructorTypeNode: (node: ConstructorTypeNode, typeParameters: NodeArray<TypeParameterDeclaration> | undefined, parameters: NodeArray<ParameterDeclaration>, type: TypeNode) => ConstructorTypeNode;
|
|
6940
7029
|
/** @deprecated Use `factory.createTypeQueryNode` or the factory supplied by your transformation context instead. */
|
|
6941
|
-
const createTypeQueryNode: (exprName: EntityName) => TypeQueryNode;
|
|
7030
|
+
const createTypeQueryNode: (exprName: EntityName, typeArguments?: readonly TypeNode[] | undefined) => TypeQueryNode;
|
|
6942
7031
|
/** @deprecated Use `factory.updateTypeQueryNode` or the factory supplied by your transformation context instead. */
|
|
6943
|
-
const updateTypeQueryNode: (node: TypeQueryNode, exprName: EntityName) => TypeQueryNode;
|
|
7032
|
+
const updateTypeQueryNode: (node: TypeQueryNode, exprName: EntityName, typeArguments?: readonly TypeNode[] | undefined) => TypeQueryNode;
|
|
6944
7033
|
/** @deprecated Use `factory.createTypeLiteralNode` or the factory supplied by your transformation context instead. */
|
|
6945
7034
|
const createTypeLiteralNode: (members: readonly TypeElement[] | undefined) => TypeLiteralNode;
|
|
6946
7035
|
/** @deprecated Use `factory.updateTypeLiteralNode` or the factory supplied by your transformation context instead. */
|
|
@@ -6978,9 +7067,15 @@ declare namespace ts {
|
|
|
6978
7067
|
/** @deprecated Use `factory.updateInferTypeNode` or the factory supplied by your transformation context instead. */
|
|
6979
7068
|
const updateInferTypeNode: (node: InferTypeNode, typeParameter: TypeParameterDeclaration) => InferTypeNode;
|
|
6980
7069
|
/** @deprecated Use `factory.createImportTypeNode` or the factory supplied by your transformation context instead. */
|
|
6981
|
-
const createImportTypeNode:
|
|
7070
|
+
const createImportTypeNode: {
|
|
7071
|
+
(argument: TypeNode, qualifier?: EntityName | undefined, typeArguments?: readonly TypeNode[] | undefined, isTypeOf?: boolean | undefined): ImportTypeNode;
|
|
7072
|
+
(argument: TypeNode, assertions?: ImportTypeAssertionContainer | undefined, qualifier?: EntityName | undefined, typeArguments?: readonly TypeNode[] | undefined, isTypeOf?: boolean | undefined): ImportTypeNode;
|
|
7073
|
+
};
|
|
6982
7074
|
/** @deprecated Use `factory.updateImportTypeNode` or the factory supplied by your transformation context instead. */
|
|
6983
|
-
const updateImportTypeNode:
|
|
7075
|
+
const updateImportTypeNode: {
|
|
7076
|
+
(node: ImportTypeNode, argument: TypeNode, qualifier: EntityName | undefined, typeArguments: readonly TypeNode[] | undefined, isTypeOf?: boolean | undefined): ImportTypeNode;
|
|
7077
|
+
(node: ImportTypeNode, argument: TypeNode, assertions: ImportTypeAssertionContainer | undefined, qualifier: EntityName | undefined, typeArguments: readonly TypeNode[] | undefined, isTypeOf?: boolean | undefined): ImportTypeNode;
|
|
7078
|
+
};
|
|
6984
7079
|
/** @deprecated Use `factory.createParenthesizedType` or the factory supplied by your transformation context instead. */
|
|
6985
7080
|
const createParenthesizedType: (type: TypeNode) => ParenthesizedTypeNode;
|
|
6986
7081
|
/** @deprecated Use `factory.updateParenthesizedType` or the factory supplied by your transformation context instead. */
|