An open API service indexing awesome lists of open source software.

https://github.com/eriklharper/postcss-nested-import

@import stylesheets inside nested CSS
https://github.com/eriklharper/postcss-nested-import

postcss

Last synced: about 1 year ago
JSON representation

@import stylesheets inside nested CSS

Awesome Lists containing this project

README

          

PostCSS Nested Import

PostCSS plugin for importing other stylesheet source files anywhere in your CSS.



GitHub CI test

Before:

```css
/* vendor.css */
.vendor {
background: silver;
}

/* index.css */
:global {
@nested-import './vendor.css';
}
```

After:

```css
:global {
.vendor {
background: silver;
}
}
```

## Usage

```js
postcss([require("postcss-nested-import")]);
```

See [PostCSS](https://github.com/postcss/postcss) docs for examples for your environment.