postcss / postcss-cli

CLI for postcss
Other
840 stars 93 forks source link

--replace will ignore options in postcss.config.js #222

Closed steveblue closed 6 years ago

steveblue commented 6 years ago

When using the following command

postcss out-sass/src/components/slider.component.css --config postcss.config.js --output src/components/slider.component.css

postcss-cli honors the options configured in postcss.config.js

module.exports = {
    plugins: [
        require('postcss-discard-comments')(),
        require('postcss-filter-gradient')(),
        require('autoprefixer')({ remove: false }),
        require('css-mqpacker')({ sort: true }),
        require('postcss-csso')({})
    ]
}

but when using --replace it does not

postcss src/components/slider.component.css --config postcss.config.js --replace
RyanZim commented 6 years ago

Try without the config option; it’s not needed if you’re using the standard file location.

RyanZim commented 6 years ago

Assuming this is fixed since there's no response.