NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
npm · #1924 most downloaded on npm
TypeScript compiler wrapper for static analysis and code manipulation.
Last release 5 months ago
12 Apr 2026
Ships fairly regularly
a new release about every 3 months
Most releases are documented
notes for 40 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
8 years old
89 releases · first in 2019
Nothing published for this version
Thanks to @cancerberoSgx for discovering this was a node >= 11 issue.
<a name="4.0.1"></a>
Thanks to @cancerberoSgx for discovering this was a node >= 11 issue.
<a name="4.0.0"></a>
One column per quarter.
Nothing published for this version
DiagnosticMessageChain#getNext() now returns an array to match TS 3.6.
SourceFile#getReferencedFiles() to getPathReferenceDirectives(). (578adc7)DiagnosticMessageChain#getNext() now returns an array to match TS 3.6. (4943196)Project#createSourceFile with an existing file name now suggests to add the overwrite option. (3022bb8)Type#getPropertyOrThrow (c929c6c)SourceFile#getReferencedSourceFiles(), #getNodesReferencingOtherSourceFiles(), and #getLiteralsReferencingOtherSourceFiles(). (c245acc)SourceFile#getReferencedFiles() is now getPathReferenceDirectives().This was done to prevent confusion with upcoming methods in #680. The name was chosen because it is similar to the methods getTypeReferenceDirectives() and getLibReferenceDirectives().
CodeBlockWriter#indentBlock is now indent. withHangingIndentation is now hangingIndent. withHangingIndentationUnlessBlock is now hangingIndentUnlessBlock.DiagnosticMessageChain#getNext() now returns an array to match TS 3.6.DirectoryEmitResult#getEmitSkipped() was removed. Check the output file paths and skipped file paths instead as that's more accurate.CompilerExtendedComment is now called CompilerCommentNode.<a name="3.1.3"></a>
<a name="3.1.2"></a>
<a name="3.1.1"></a>
<a name="3.1.0"></a>
Nothing published for this version
Nothing published for this version
Nothing published for this version
Add DirectoryEmitResult#getSkippedFilePaths().
ClassLike and TypeElementMembered nodes would not get the correct "add" index when a comment member node was present.
Node#getText({ trimLeadingIndentation: true }) indenting more than it should. (a2210de)globalThis node returned from a symbol) (b9b0cb0)StructureTypeGuards methods to remove word Node and Declaration in certain cases. (92331e1)Node#forEachChild is now aligned with the compiler API (same with forEachDescendant). (27fa43a)SourceFile#getTypeReferenceDirectives() and #getReferencedFiles() better reflects the compiler api. (350bacb)renameNode and renameLocations from the language service. (72f0e1d)ObjectLiteralElementMemberStructures to ObjectLiteralExpressionPropertyStructures. (98f00d2)Symbol#getExportSymbol and TypeChecker#getExportSymbolOfSymbol. (5fce598)Node#getLocals, #getLocalByName, #getLocalByNameOrThrow (c343de3)ClassLikeDeclarationBase. (f55850b)TypeElementMemberedNode. (93a070d)writer.withHangingIndent(() => {}). Also better hanging indent printing (a544e55), closes #616Writers alias for WriterFunctions. (79c6694)prefixText and suffixText when renaming. (9326100)RenameLocation - Add getPrefixText() and getSuffixText() (3cb7a7f)Node#getSymbolsInScope(meaning) and TypeChecker#getSymbolsInScope(node, meaning). (25ab43d)SourceFile#indent() and deindent(). (17eefea)renameNode and renameLocations are removed from the language service. To be consistent, the language service should not have methods that manipulate nodes.SourceFile#getTypeReferenceDirectives() and #getReferencedFiles() now return the objects similar to what the compiler api returns.Node#forEachChild is now aligned with the compiler API (same with forEachDescendant). These methods now stop when a value is returned in a callback and they will return the returned value.ObjectLiteralElementMemberStructures alias is now called ObjectLiteralExpressionPropertyStructures. This is a more correct name as an object literal expression has "properties" rather than "members" in the compiler api.StructureTypeGuards methods to remove word Node and Declaration in certain cases.<a name="2.3.0"></a>
Thanks to @marikaner for implementing the feature in this release!
Add Project#getModuleResolutionHost()
Project#getModuleResolutionHost() (9085100)<a name="2.1.2"></a>
<a name="2.1.1"></a>
<a name="2.1.0"></a>
Nothing published for this version
Nothing published for this version
TypeParameterDeclaration#getStructure() should trim leading indentation on contraint and default.
TypeParameterDeclaration#getStructure() should trim leading indentation on contraint and default. (ec971ce)#getStatement() to work with type guards. (02c8d89)StructureTypeGuards. (6138472)ConditionalTypeNode. (5e3e74c)InferTypeNode. (ec4b3f2)ThisTypeNode. (6655c51)<a name="2.0.0"></a>
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Add VariableDeclaration#getVariableStatement()
<a name="1.2.0"></a>
Thanks to @Pineapples and @schiller-manuel for their contributions for this release!
Thanks to @Pineapples and @schiller-manuel for their contributions for this release!
<a name="1.1.0"></a>
Thanks to @Pineapples for implementing these features!
Thanks to @Pineapples for implementing these features!
<a name="1.0.0"></a>
Library was renamed to ts-morph.
Your coding agent can read these notes before it upgrades. Set up the MCP server →