Preparing for system design interviews?  Try bugzed.com →

CSS Selector Parser

JSON →
library 3.3.0 ·javascript
verified Jun 17, 2026

css-selector-parser is a high-performance JavaScript/TypeScript library designed for parsing CSS selectors into a comprehensive Abstract Syntax Tree (AST). It provides an AST-based object model that enables programmatic manipulation, analysis, and transformation of selectors through its visitor pattern implementation. The library offers full compliance with a wide array of CSS selector specifications, including CSS1, CSS2, CSS3, and Selectors Level 4, with an additional "progressive" mode for handling unknown or future pseudo-classes and attributes. Currently at version 3.3.0, the package suggests an active development cycle, evidenced by its multiple migration guides for major versions. Key differentiators include its speed, memory efficiency, extensive TypeScript support for a well-documented API, and an interactive playground for real-time testing and visualization of AST outputs.

total hits 14
actors 5 distinct systems
last hit 16d ago ByteDance
GPTBot
4
Amazonbot
4
Script
1
ByteDance
1

top countries 🇺🇸 United States · 🇨🇦 Canada · 🇫🇷 France · 🇩🇪 Germany · 🇸🇬 Singapore