whitneyit / postcss-strip-units

MIT License
7 stars 1 forks source link

Error when using with PostCSS 7.0.14 #6

Closed rodrigodagostino closed 5 years ago

rodrigodagostino commented 5 years ago

I was trying this plugin for the first time, and I ran into an error. Even if I don't call the strip() function in my code, I still receive the same error messages (3 times to be precise):

Unknown error from PostCSS plugin. Your current PostCSS version is 7.0.14, but postcss-strip uses 4.1.16. Perhaps this is the source of the error below.
css.eachDecl is not a function

This is how I'm calling it in my gulpfile.js:

var stripe = require('postcss-strip');

.pipe( plugin.postcss( [
    cssvariables(),
    colormod(),
    stripe( {
        functionName : 'removeUnit'
    } ),
    rem( {
        fallback: true,
    } ),
] ) )
rodrigodagostino commented 5 years ago

I'm deeply sorry, I've just realised I was using a different plugin called postcss-strip.

Yours is working perfectly fine. Thank you so much for your work, it came in really handy :)