1.0.2 • Published 1 year ago

postcss-unit-replace v1.0.2

Weekly downloads
-
License
MIT
Repository
-
Last release
1 year ago

postcss-unit-replace

NPM Package License: MIT

PostCSS plugin to replace the css value

postcss([require('postcss-unit-replace')])
/* before */
.foo {
  height: 12cc;
}

/* after */
.foo {
  height: 12px;
}

Options

interface Options {
  before?: string
  after?: string
}

Use with Options

postcss([require('postcss-unit-replace')])({
  after: 'qq', // By default, it is 'cc'
  before: 'pt', // By default, it is 'px'
})
/* before */
.foo {
  height: 12qq;
}

/* after */
.foo {
  height: 12pt;
}

Installation

npm install --save-dev postcss postcss-unit-replace

Usage

See PostCSS docs for examples for your environment (webpack, gulp, grunt).

1.0.2

1 year ago

1.0.1

1 year ago

1.0.0

1 year ago

0.0.1

1 year ago