JSPM

postcss-remove-inline-comments

0.0.2
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 16
  • Score
    100M100P100Q57941F
  • License MIT

A plugin to remove inline CSS comments from compilation

Package Exports

  • postcss-remove-inline-comments

Readme

postcss-remove-inline-comments

A plugin to remove inline CSS comments from compilation. It Forked from postcss-strip-inline-comments, Because there are some warnings in postcss@8.

/* This comment will remain */
// This comment will be removed
body {
  // This comment will also be removed
  background-color: black;
}
// And so will this one

Usage

You need to have a compliant parser, currently either postcss-scss or sugarss already parsing your postcss for this plugin to work.

Install

npm install postcss-remove-inline-comments --save-dev

postcss.config.js

module.exports = {
  parse: require('postcss-scss'),
  plugins: [
    require('postcss-remove-inline-comments')
  ]
}