postcss-alias

postcss-alias JS library on GitHub postcss-alias JS library on npm Download postcss-alias JS library

PostCSS plugin that lets you create custom aliases for CSS properties with an @rule

Version 2.0.0 License MIT Vulnerabilities 2
postcss-alias has no homepage
postcss-alias JS library on GitHub
postcss-alias JS library on npm
Download postcss-alias JS library
Keywords
postcsscsspostcss-pluginalias
No default JS file set by the package author so the URL is guessed. You can always browse all package files to use another one.

PostCSS Alias

NPM version Build Status Dependency Status

PostCSS plugin that lets you create custom aliases for CSS properties with an @alias rule.

Part of Rucksack - CSS Superpowers.

Input

@alias {
  fs: font-size;
  bg: background;
}

.aliased {
  fs: 16px;
  bg: white;
}

Output

.aliased {
  font-size: 16px;
  background: white;
}

Note: Aliases in property values (eg: transition: bg 200ms) are not supported

Usage

postcss([ require('postcss-alias') ])

See PostCSS docs for examples for your environment.


MIT © Sean King