Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rajdee/postcss-autoimport
PostCSS plugin for automatically import global dependencies.
https://github.com/rajdee/postcss-autoimport
global import postcss postcss-plugin
Last synced: 9 days ago
JSON representation
PostCSS plugin for automatically import global dependencies.
- Host: GitHub
- URL: https://github.com/rajdee/postcss-autoimport
- Owner: rajdee
- License: mit
- Created: 2018-04-03T09:58:03.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2020-10-20T10:17:51.000Z (about 4 years ago)
- Last Synced: 2024-04-26T01:04:31.148Z (7 months ago)
- Topics: global, import, postcss, postcss-plugin
- Language: JavaScript
- Homepage:
- Size: 128 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# PostCSS Autoimport [![Build Status][ci-img]][ci]
[PostCSS] plugin for automatically import global dependencies.
[PostCSS]: https://github.com/postcss/postcss
[ci-img]: https://travis-ci.org/rajdee/postcss-autoimport.svg
[ci]: https://travis-ci.org/rajdee/postcss-autoimport## Installation
```console
$ npm install -D postcss postcss-autoimport$ yarn add -D postcss postcss-autoimport
```## Usage
```js
postcss([ require('postcss-autoimport')({
paths: [
'./css/common/_variables.css',
'./css/common/functions/',
...
]
}) ])
```### Options
#### `paths`
Type: `Array`
Default: `[]`An array of paths to directories or files which should be imported
#### `root`
Type: `String`
Default: process.cwd()Define the root where to resolve path.
See [PostCSS] docs for examples for your environment.