postcss-modules-resolve-from-alias
v1.3.0
Published
A CSS Modules transform to provide aliases for composes paths
Downloads
266
Readme
CSS Modules: Resolve imports from aliases
With this config:
{
'css': 'src/style'
}
transforms:
.myClass {
composes: button from "css/button.css";
color: green;
}
into:
.myClass {
composes: button from "src/style/button.css";
color: green;
}
Options
An object, where each key/value pair represents an alias for composes
import paths.
- key -
composes
import path prefix - value - replacement value for the import path prefix
Both keys and values may include a trailing /
.
If there is no trailing /
, then one is implied.
Building
npm install
npm build
npm test
Development
npm watch
will watchsrc
for changes and rebuildnpm autotest
will watchsrc
andtest
for changes and retest
License
MIT