A lightweight CSS parser in JavaScript / TypeScript.
The returned structure
[
{
selector: string;
type?: string;
children?: [...];
comments?: string;
styles?: string;
rules?: [
{
key: string;
value: string;
defective?: boolean;
}, ...
]
}, ...
]
Install the css-parser from the github repo.
npm install sibvrv/css-parser
npm run build
npm run test