Skip to content

v3.0.0

Compare
Choose a tag to compare
@shellscape shellscape released this 04 Mar 16:12
· 56 commits to master since this release

Major Version 3

This is a major rewrite from top to bottom and contains many breaking changes. The rewrite leverages PostCSS itself under the hood. That means it uses the same tokenizer and parser, with some modifications. The last major update to PostCSS provided consumers with an outstanding model to inherit and extend from the base classes to create derived parsers. That means we now benefit from the rock-solid tokenizing in PostCSS without having to reinvent the wheel, and without introducing new bugs.

This also allows for use of the base PostCSS Node classes, without redefining or duplicating their functionality. Tasks like walking nodes, or inspecting Node properties you'd expect in PostCSS are now identical.

Breaking Changes

Some Node types have changed. Most notably, all characters which can be considered "punctuation" have been moved into the Punctuation Node. Additionally, decorative property names on Nodes have changed in some instances. The full API documentation has more details.

Old Node Type New Node Type
AtWord AtWord
Colon Punctuation
Comma Punctuation
Comment Comment
Func Func
Numbr Numeric
Operator Operator
Paren Punctuation
Str Quoted
UnicodeRange UnicodeRange
Word Word