npm / recast
recast
What changed in recast 0.24, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-09.
13 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initrecast 0.2413 changes
Fixes and other changes 13
Preserves dangling comments when reprinting containers.
Preserves multiline template values when reprinting changed blocks.
Source indentation no longer stacks before JSX closing tags.
Comments on object destructuring assignments are no longer parenthesized when printed.
Dangling if consequents are wrapped in braces when printing an outer else.
The
ecmaVersionoption is now respected instead of hardcoding ES6.Reprinting now keeps
typeandtypeofon Flow import specifiers.Reprinting now preserves changes to import aliases.
Reprinting elements now preserves significant JSX whitespace around expressions.
Nodes whose children share source ranges are now reprinted.
Reprinting parenthesizes
??when combined with||or&&.TypeScript declarations for per-context trailing comma options are corrected.
Reprinting now parenthesizes update expressions in optional chains.