css-tree breaking changes
css-tree 3.0.0 (September 11, 2024) is its newest release with breaking changes, 33 of them. The first: Removed DefinitionSyntax.syntaxError. Every breaking API change we have recorded in css-tree on npm: 56 breaking changes in 2 versions. Below, its 2 versions with breaking changes, newest first, removals and renames first, each with its source.
Updated December 4, 2026
On this page
Latest version 3.2.1, released March 5, 2026.
Its 2.0.0 release requires Node.js 14.16 or later. Node.js end of life dates.
css-tree 3.0.0 breaking changes
- Removed
DefinitionSyntax.syntaxError
DefinitionSyntax.syntaxError was removed in css-tree 3.0.0 npmjs.com - Removed
GenerateHandlers.children
GenerateHandlers.children was removed in css-tree 3.0.0 npmjs.com - Removed
GenerateHandlers.chunk
GenerateHandlers.chunk was removed in css-tree 3.0.0 npmjs.com - Removed
MediaFeature
Media features are now parsed as Feature nodes with kind "media" instead of MediaFeature nodes. npmjs.com - Removed
MediaQuery.children
MediaQuery.children was removed in css-tree 3.0.0 npmjs.com - Removed
MediaQueryPlain.children
MediaQueryPlain.children was removed in css-tree 3.0.0 npmjs.com - Removed
Parentheses
The @supports parser now emits Condition or SupportsDeclaration nodes instead of Parentheses, so code matching Parentheses must change. github.com - Removed
SyntaxParseError.input
SyntaxParseError.input was removed in css-tree 3.0.0 npmjs.com - Removed
SyntaxParseError.rawMessage
SyntaxParseError.rawMessage was removed in css-tree 3.0.0 npmjs.com - Behavior changed
Atrule
Atrule nodes for a block now include the { and } characters, which changes their output and any code that reads them. github.com - Behavior changed
Block
The Block node no longer includes the { and } characters, so code reading its content must account for that. github.com - Behavior changed
MediaQuery
MediaQuery nodes now have modifier, mediaType and condition fields in place of the old structure, so code reading them must be updated. github.com - Behavior changed
parseWithFallback
parseWithFallback() rewinds the token index before running the fallback, so the fallback starts from a different position than before. github.com - Behavior changed
Ratio
Ratio parts are now nodes, can be any number or function, and the right part may be omitted, so code expecting strings must change. github.com - Behavior changed
Rule
Rule nodes for a block now include the { and } characters, which changes their output and any code that reads them. github.com - Signature changed
CssNode
Was type CssNode = | AnPlusB | Atrule | AtrulePrelude | AttributeSelector | Block | Brackets | CDC | CDO | ClassSelector | Combinator | Comment | Declaration | DeclarationList | Dimension | FunctionNode | Hash | IdSelector | Identifier |... npmjs.com - Signature changed
CssNodePlain
Was type CssNodePlain = | AnPlusB | AtrulePlain | AtrulePreludePlain | AttributeSelector | BlockPlain | BracketsPlain | CDC | CDO | ClassSelector | Combinator | Comment | DeclarationPlain | DeclarationListPlain | Dimension |... npmjs.com - Signature changed
DefinitionSyntax.generate
Was generate(node: DSNode, options?: DSGenerateOptions): string; now generate(node: DSNode, options?: DSGenerateOptions | DSGenerateDecorateFn): string. npmjs.com - Signature changed
DSGenerateOptions.decorate
Was decorate?: ((result: string, node: DSNode) => void) | undefined; now decorate?: DSGenerateDecorateFn | undefined. npmjs.com - Signature changed
DSNode
Was type DSNode = | DSNodeAtWord | DSNodeComma | DSNodeFunction | DSNodeGroup | DSNodeKeyword | DSNodeMultiplier | DSNodeProperty | DSNodeString | DSNodeToken | DSNodeType; now type DSNode = | DSNodeAtWord | DSNodeBoolean | DSNodeComma |... npmjs.com - Signature changed
DSNodeMultiplied
Was type DSNodeMultiplied = | DSNodeFunction | DSNodeGroup | DSNodeKeyword | DSNodeProperty | DSNodeString | DSNodeType; now type DSNodeMultiplied = | DSNodeFunction | DSNodeGroup | DSNodeKeyword | DSNodeProperty | DSNodeString |... npmjs.com - Signature changed
fork
Was function fork(extension: {atrules?: Record<string, string> | undefined; properties?: Record<string, string> | undefined; types?: Record<string, string> | undefined; cssWideKeywords?: Array<string> | undefined;}): {lexer: Lexer}; now... npmjs.com - Signature changed
GenerateHandlers.node
Was node: (node: CssNode) => void; now node(node: CssNode): void. npmjs.com - Signature changed
GenerateHandlers.result
Was result: () => string; now result(): string. npmjs.com - Signature changed
List.insert
Was insert(item: ListItem<TData>, before: ListItem<TData>): List<TData>; now insert(item: ListItem<TData>, before?: ListItem<TData> | null): List<TData>. npmjs.com - Signature changed
List.pop
Was pop(): ListItem<TData> | undefined; now pop(): ListItem<TData> | null. npmjs.com - Signature changed
List.replace
Was replace(oldItem: ListItem<TData>, newItemOrList: List<TData> | ListItem<TData>): List<TData>; now replace(oldItem: ListItem<TData>, newItemOrList: List<TData> | ListItem<TData>): void. npmjs.com - Signature changed
List.shift
Was shift(): ListItem<TData> | undefined; now shift(): ListItem<TData> | null. npmjs.com - Signature changed
Ratio.left
Was left: string; now left: NumberNode | FunctionNode. npmjs.com - Signature changed
Ratio.right
Was right: string; now right: NumberNode | FunctionNode | null. npmjs.com - Signature changed
SyntaxMatchError
Was class SyntaxMatchError extends SyntaxError; now interface SyntaxMatchError extends SyntaxError. npmjs.com - Signature changed
SyntaxReferenceError
Was class SyntaxReferenceError extends SyntaxError; now interface SyntaxReferenceError extends SyntaxError. npmjs.com - Signature changed
WalkOptions
Was type WalkOptions = | WalkOptionsVisit<AnPlusB> | WalkOptionsVisit<Atrule> | WalkOptionsVisit<AtrulePrelude> | WalkOptionsVisit<AttributeSelector> | WalkOptionsVisit<Block> | WalkOptionsVisit<Brackets> | WalkOptionsVisit<CDC> |... npmjs.com
css-tree 2.0.0 breaking changes
- Removed
Code running on Node.js older than 14.16 can no longer use this release; upgrade Node.js to 14.16 or later. github.com - Removed
Lexer.matchDeclaration
Lexer#matchDeclaration() no longer exists; stop calling it. github.com - Removed
List.each
List#each() is gone; use List#forEach() instead. npmjs.com - Removed
List.eachRight
List#eachRight() is gone; use List#forEachRight() instead. npmjs.com - Removed
List.getSize
Use the List#size getter instead of calling List#getSize(). npmjs.com - Removed
SyntaxError.parseError
The parseError field no longer exists on the parser's SyntaxError. github.com - Removed
TokenStream.getTokenLength
TokenStream#getTokenLength() no longer exists; stop calling it. github.com - Removed
TokenStream.skipWS
TokenStream#skipWS() no longer exists; stop calling it. github.com - Removed
WhiteSpace
The parser stops creating WhiteSpace nodes, except for a custom property with a single whitespace token as value. github.com - Renamed
chunk
Custom generator handlers must use token() to output a single token, and tokenize() for strings. github.com
And 13 more in this version. Sign up to see every change
Check your code
These are the changes. To see which of them reach your code, scan a public repository, or have your coding agent call check_code with your manifest or lockfile over MCP. The API reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

Put your code on continuous maintenance.
Scan a public repository now, or give your agent one line.
See how out of date your code is.
Tell your agent what changed since it was trained.
claude mcp add --transport http since https://api.since.dev/mcpCodex, Cursor and any MCP client use https://api.since.dev/mcp.