JSPM

pull-css

0.1.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 1
  • Score
    100M100P100Q11769F
  • License MIT

Parse CSS into ASTs through a pull stream, or vice versa.

Package Exports

  • pull-css

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (pull-css) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

pull-css NPM version Build Status

Parse CSS into ASTs through a pull stream, or vice versa.

pull(
  source(),
  css(), // parse source as CSS
  // ...
)

Installation

$ npm install --save pull-css

API

css(options)

Parse a pull-stream source with css

  • options (Object): Options passed to css.parse

Returns a through stream that pulls tokens.

pull(
  pull.values([
    'div { color: red }'
  ]),
  css(),
  // ...
)

css.stringify(options)

Stringify a pull-stream source that is a css AST (probably originating from css())

Returns a through pull stream that pulls strings.

pull(
  pull.values([
    'div { color: red }'
  ]),
  css(),
  // do transformations on ast...
  // then serialize:
  css.serialize(),
  // ...
)

License

MIT © Jamen Marz