# cssstyle

> An implementation of the CSSStyleDeclaration class from the CSS Object Model specification

Latest version **6.2.0** (published 2026-03-02) · MIT license · 0 weekly downloads

## Install

```sh
npm install cssstyle
pnpm add cssstyle
yarn add cssstyle
bun add cssstyle
```

## Health

**Score 58/100 (C)** — status: stable.

Positive: has types package; no vulnerabilities; has provenance; high quality score.

Warnings: low downloads; no esm support.

## Facts

| | |
|---|---|
| Version | 6.2.0 |
| Published | 2026-03-02 |
| First published | 2012-07-11 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | separate (@types/cssstyle) |
| Module format | CommonJS |
| Node | >=20 |
| Dependencies | 4 |
| Unpacked size | 935.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 130 |
| Maintainers | chad3814, domenic, jon.sakas |
| Keywords | CSS, CSSStyleDeclaration, StyleSheet |

## Links

- npm: https://www.npmjs.com/package/cssstyle
- Repository: https://github.com/jsdom/cssstyle
- Homepage: https://github.com/jsdom/cssstyle#readme
- Issues: https://github.com/jsdom/cssstyle/issues
- npm.io page: https://npm.io/package/cssstyle

## Dependencies (4)

- [css-tree](https://npm.io/package/css-tree.md) ^3.1.0
- [lru-cache](https://npm.io/package/lru-cache.md) ^11.2.6
- [@asamuzakjp/css-color](https://npm.io/package/@asamuzakjp/css-color.md) ^5.0.1
- [@csstools/css-syntax-patches-for-csstree](https://npm.io/package/@csstools/css-syntax-patches-for-csstree.md) ^1.0.28

## Alternatives

- [style-dictionary](https://npm.io/package/style-dictionary.md) — 2.0M weekly downloads
- [postcss-merge-idents](https://npm.io/package/postcss-merge-idents.md) — 1.7M weekly downloads
- [@fontsource/noto-sans](https://npm.io/package/@fontsource/noto-sans.md) — 93.0K weekly downloads
- [uglifycss](https://npm.io/package/uglifycss.md) — 71.6K weekly downloads
- [mat4-interpolate](https://npm.io/package/mat4-interpolate.md) — 23.3K weekly downloads

## Recent versions

- 6.2.0 (latest) — 2026-03-02
- 6.1.0 — 2026-02-23
- 6.0.2 — 2026-02-22
- 6.0.1 — 2026-02-06
- 6.0.0 — 2026-02-05
- 5.3.7 — 2026-01-06
- 5.3.6 — 2025-12-31
- 5.3.5 — 2025-12-17
- 5.3.4 — 2025-12-08
- 5.3.3 — 2025-11-08
- 5.3.2 — 2025-10-31
- 5.3.1 — 2025-09-21
- 5.3.0 — 2025-09-13
- 5.2.1 — 2025-07-29
- 5.2.0 — 2025-07-28
- … 61 more at https://npm.io/package/cssstyle/versions

## README

# CSSStyleDeclaration

A Node.js implementation of the CSS Object Model [`CSSStyleDeclaration` class](https://drafts.csswg.org/cssom/#the-cssstyledeclaration-interface).

## Background

This package is an extension of the `CSSStyleDeclaration` class in Nikita Vasilyev's [CSSOM](https://github.com/NV/CSSOM), with added support for modern specifications. The primary use case is for testing browser code in a Node environment.

It was originally created by Chad Walker, it is now maintained by the jsdom community.

Bug reports and pull requests are welcome.

---
_Source: https://npm.io/package/cssstyle · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
