/postcss-nested-import

@import stylesheets inside nested CSS

Primary LanguageJavaScriptMIT LicenseMIT

PostCSS Nested Import Build Status

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

Before:

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

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

After:

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

Usage

postcss([
  require('postcss-nested-import')
])

See PostCSS docs for examples for your environment.