Packages

ts-morph

28.0.0 · 12 Apr 2026MIT46.3M / weekRepositoryHomepagenpmAtom feed

Your version

13.0.0

major20 Nov 2021Where it was published

13.0.3 is the newest release of 13.x.

In short

5 breaking1 removed7 new1 fixed1 internal

  • Breaking

    Node.isXNode(node)-like static type guard methods are now Node.isX(node) to reduce verbosity.

  • Breaking

    Targeting ES2018 instead of ES2015

  • Breaking

    Upgraded to TS 4.5

  • Breaking

    Removed already deprecated WriterFunctions and TypeGuards exports. Use Writers and Node instead.

  • Breaking

    readDirSync now returns directory entries.

  • Removed

    Remove already deprecated WriterFunctions and TypeGuards exports.

Release note

Bug Fixes

  • Do not throw an error if decorator expr is wrapped in a paren expr (c77db30), closes #1214

Code Refactoring

  • Removed

    Remove already deprecated WriterFunctions and TypeGuards exports.

Features

  • Add AssertClause and AssertEntry

  • Add Node.hasStructure type guard.

  • Change readDirSync to return directory entries instead of file paths

  • Make Structure.isX function more flexible (a54dd69), closes #1219

  • Type only methods for ImportSpecifier and ExportSpecifier

  • TypeScript 4.5 support

  • Wrap more JS doc nodes

Breaking changes

  • Breaking

    Node.isXNode(node)-like static type guard methods are now Node.isX(node) to reduce verbosity.

  • Breaking

    Targeting ES2018 instead of ES2015

  • Breaking

    Upgraded to TS 4.5

  • Breaking

    Removed already deprecated WriterFunctions and TypeGuards exports. Use Writers and Node instead.

  • Breaking

    readDirSync now returns directory entries.

A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.