Unknown error from PostCSS plugin. Your current PostCSS version is 8.3.0, but postcss-preset-env uses 7.0.36
Asked Answered
T

3

11

Unknown error from PostCSS plugin. Your current PostCSS version is 8.3.0, but postcss-preset-env uses 7.0.36. any one knows why this error is happening?

Titania answered 17/8, 2021 at 4:59 Comment(0)
E
4

You could be missing the .browserslistrc in the root of the project. If you pulled down from source control make sure whoever submitted the files originally remembered to include this file.

Evanthe answered 13/9, 2021 at 23:36 Comment(3)
my project already had the file .browserslistrc, adjusting its content to a newly created with angular-cli stopped giving the errorDiplex
After migrating from Angular 11 to 12 I had the same error. After updating .browserslistrc to a newer version picked from another angular 12 project worked for me as wellKersten
Could you add a note to also generate a clean project using angular 12 cli and compare the package.json dependencies to your project's dependencies. Your solution helped me, but I also had to fix some dependencies. Biggest one seemed to be tslib which was completely missingConrado
A
0

Deleting the node_modules folder and the yarn.lock file and reinstalling fixed the issue for me.

Archicarp answered 24/9, 2021 at 8:5 Comment(0)
B
-1

I think you need this pr https://github.com/csstools/postcss-preset-env/pull/211 to be merged.. then it should work.

There is a version mismatch in your postcss and the postcss version required by postcss-preset-env.

Or you could try downgrading your postcss.. but that will probably break everything else.

Bechtold answered 27/8, 2021 at 9:27 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.