Changelog
3.20.0
Features:
findImports
and findImportLikeNodes
take an additional parameter ignoreFileName
. The default value for this paramter is true
to remain backwards compatible. When set to false
, it matches the behavior of TypeScript, i.e. only looks for require
in JavaScript files.Bugfixes:
getJsDoc
for EndOfFileToken
now returns JSDoc
comments whose contents are usable with the type checkerChangelog
3.19.1
Bugfixes:
getSymbolOfClassLikeDeclaration
no longer crashes on anonymous mixin classesChangelog
3.19.0
Features:
getSymbolOfClassLikeDeclaration
to retrieve the symbol of class declarations and expressions regardless whether they have a name or notgetBaseOfClassLikeDeclaration
to conventiently get the expression after extends
getBaseClassMemberOfClassElement
to look up the declaration of a class member in the base classBugfixes:
getConstructorTypeOfClassLikeDeclaration
now really returns the constructor type (the static side of the class), previously it returned the instance typehasExhaustiveCaseClauses
allows additional case clauses with null
, undefined
and never
Changelog
3.18.0
Features:
callExpressionAffectsControlFlow
to determine whether a CallExpression affects control flow by returning never
or asserts
hasExhaustiveCaseClauses
to determine whether a SwitchStatement's CaseClauses handle every possible valueendsControlFlow
and getControlFlowEnd
take an optional checker
parameter to recognize exhaustive SwitchStatements and control flow effects of CallExpressionsformatPseudoBigInt
converts TypeScript's representation of a BigInt to its literal representation as you would write it in your source codegetAstNodeAtPosition
similar to getTokenAtPosition
, but only operates on AST NodesremoveOptionalChainingUndefinedMarkerType
and isOptionalChainingUndefinedMarkerType
to handle types originating in an optional chainfindImports
and findImportLikeNodes
: prepare for import assertionsgetTsCheckDirective
as new name for getCheckJsDirective
getCheckJsDirective
is now deprecatedBugfixes:
getUsageDomain
: handles NamespaceExport and NamedTupleMembergetPropertyName
: handles parentheses and negative numeric literals, excludes RegExp literals and private identifiersgetSingleLateBoundPropertyNameOfPropertyName
and getLateBoundPropertyNamesOfPropertyName
: handles private identifiershasAccessModifier
: handles JSDoc access modifierhasSideEffects
: correctly determines side effects of (static) property initializersisExpressionValueUsed
: handle nullish coalescing and conditional assignment operatorscanHaveJsDoc
: aligned with upstream changes in TypeScriptisCompilerOptionEnabled
:
noUncheckedIndexedAccess
requires strictNullChecks
checkJs
implies allowJs
emitDeclarationOnly
requires declaration
isInConstContext
: handle template string interpolationsChangelog
3.17.1
Bugfixes:
isValidJsxIdentifier
, isValidPropertyAccess
, isValidPropertyName
: fix unicode character width handlingChangelog
3.17.0
Features:
isValidJsxIdentifier
added an optional parameter to specify the target ECMAScript versionBugfixes:
isValidJsxIdentifier
now handles astral plane charactersChangelog
3.16.0
Features:
getIteratorYieldResultFromIteratorResult
to extract the yield
ed type from IteratorResult<TYield, TReturn, TNext>
Changelog
3.15.0
Features:
isValidIdentifier
, isValidPropertyName
, isValidPropertyAccess
, isValidNumericLiteral
added an optional parameter to specify the target ECMAScript versionBugfixes:
isValidPropertyName
, isValidPropertyAccess
now handle astral plane characters