GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - shellscape/postcss-values-parser: A CSS property value parser for PostCSS

BranchesTags
Open more actions menu

Latest commit

 

History

138 Commits
138 Commits

Folders and files

NameName
Last commit message
Last commit date
.github
.github
 
 
.husky
.husky
 
 
dist
dist
 
 
docs
docs
 
 
perf
perf
 
 
src
src
 
 
test
test
 
 
.editorconfig
.editorconfig
 
 
.gitattributes
.gitattributes
 
 
.gitignore
.gitignore
 
 
.nvmrc
.nvmrc
 
 
.oxlintrc.json
.oxlintrc.json
 
 
.prettierignore
.prettierignore
 
 
.prettierrc
.prettierrc
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
ava.config.js
ava.config.js
 
 
package.json
package.json
 
 
pnpm-lock.yaml
pnpm-lock.yaml
 
 
pnpm-workspace.yaml
pnpm-workspace.yaml
 
 
tsconfig.json
tsconfig.json
 
 
vitest.config.ts
vitest.config.ts
 
 

Repository files navigation



postcss-values-parser actions size

A CSS property value parser that uses css-tree for parsing, and models nodes on top of PostCSS’s Node/Container/Root classes so the API feels familiar to PostCSS users.

This package powers part of Prettier. Please consider becoming a sponsor if you find this package useful or are a Prettier user. https://github.com/sponsors/shellscape

Install

Using npm:

npm install postcss-values-parser --save-dev

Requirements

  • Node.js >= 20.19.0
  • PostCSS >= 8.4.14 (peer dependency)

Note: This package is ESM‑only. Use import in Node.js. In CommonJS on Node >= 20.19.0, require() can load ES modules:

// CommonJS (Node >= 20.19.0)
const { parse } = require('postcss-values-parser');

Benefits

  • Uses css-tree for fast, standards‑compliant parsing
  • Builds PostCSS‑style nodes for a familiar API
  • Doesn't strip characters; e.g., parentheses are preserved in the AST
  • Full AST traversal
  • Optional walker helpers (registerWalkers(Container)) to walk by node type
  • Convenience methods to stringify nodes
  • Provides convenience properties for number units, colors, etc.

Usage

Please see the Documentation for general use and further information on using the package.

Meta

CONTRIBUTING

LICENSE (Mozilla Public License)

About

A CSS property value parser for PostCSS

Topics

csscssnextlesshintparsepostcsspostcss-values-parservalues

Resources

Readme
MPL-2.0 license

Contributing

Contributing
Activity

Stars

62 stars

Watchers

3 watching

Forks

31 forks
Report repository

Releases

Sponsor this project

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.