Socket
Socket
Sign inDemoInstall

tsutils

Package Overview
Dependencies
2
Maintainers
1
Versions
94
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install
Previous1345
10Next

3.14.0

Diff

Changelog

Source

3.14.0

Features:

  • added getInstanceTypeOfClassLikeDeclaration and getConstructorTypeOfClassLikeDeclaration
  • added AccessKind.Delete to getAccessKind: getAccessKind(node) & AccessKind.Modification can now be used to restore the old behavior of isReassignmentTarget(node)
ajaff
published 3.13.0 •

Changelog

Source

3.13.0

Features:

  • getAccessKind determines whether an expression is read from, written to or both
  • optimized getPropertyOfType for unambiguous property names to partially work around https://github.com/microsoft/TypeScript/issues/31565

Bugfixes:

  • isReassignmentTarget no longer returns true for DeleteExpression as it doesn't assign a value to the operand
ajaff
published 3.12.0 •

Changelog

Source

3.12.0

Features:

  • getLateBoundPropertyNamesOfPropertyName returns all statically analyzable names of a property, method, ...
  • getSingleLateBoundPropertyNameOfPropertyName returns the literal name of a property, method, ... if statically analyzable

Bugfixes:

  • fixed circular import
ajaff
published 3.11.0 •

Changelog

Source

3.11.0

Features:

  • typeguards: isNumericOrStringLikeLiteral, isTupleTypeReference
  • intersectionTypeParts as counterpart to unionTypeParts
  • someTypePart to execute a callback for each union or intersection constituent until the callback returns true
  • getPropertyOfType looks up a property by its escaped name
  • isPropertyReadonlyInType determines whether a property in a given type cannot be written to
  • symbolHasReadonlyDeclaration determines if a Symbol has any readonly or constant declaration
  • isNumericPropertyName determines whether a property name would match an index signature
  • isBindableObjectDefinePropertyCall returns true for statically analyzable forms of Object.defineProperty(o, 'p', {value, writable})
  • isReadonlyAssignmentDeclaration determines whether an Object.defineProperty call is known to result in a readonly property
  • getLateBoundPropertyNames returns all known property names of an expression
  • getPropertyNameFromType extracts the property name of literal types
  • isWellKnownSymbolLiterally to recognize expressions in the form of Symbol.<name>
  • getPropertyNameOfWellKnownSymbol returns the escaped name for a well known symbol literal
  • unwrapParentheses returns the first child expression that is not a ParenthesizedExpression
ajaff
published 3.10.0 •

Changelog

Source

3.10.0

Features:

  • isCompilerOptionEnabled: incremental is implicitly enabled by composite

Bugfixes:

  • collectVariableUsage/getUsageDomain: no longer treat as const as type usage
ajaff
published 3.9.1 •

Changelog

Source

3.9.1

Bugfixes:

  • reverted invalid deprecation of canHaveJsdoc
  • fixed condition in parseJsdocOfNode
ajaff
published 3.9.0 •

Changelog

Source

3.9.0

Features:

  • added typeguards: isNullLiteral and isBooleanLiteral
ajaff
published 3.8.0 •

Changelog

Source

3.8.0

Features:

  • exposes typeguards for typescript@3.2 by default
  • added utilities: isConstAssertion and isInConstContext
ajaff
published 3.7.0 •

Changelog

Source

3.7.0

Features:

  • added isBlockScopedDeclarationStatement
  • added isInSingleStatementContext
ajaff
published 3.6.0 •

Changelog

Source

3.6.0

Features:

  • added getCheckJsDirective utility to parse // @ts-check and // @ts-nocheck pragmas
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc