Skip to content

PostCSS 8 for end users

Andrey Sitnik edited this page Dec 14, 2021 · 18 revisions

PostCSS 8 does not bring significant API changes for end-users. We dropped support for old Node.js versions, but API was not changed.

PostCSS 8 supports plugins from PostCSS 7. You just need to update postcss dependency and tool, which run postcss (like postcss-loader or postcss-cli). But some PostCSS runners didn’t publish a new version with PostCSS 8.

Webpack

✅ Supports PostCSS 8

  1. Update postcss-loader to >= 4.0.3.
  2. Add postcss dependency to your project or update it to >= 8.1.

CLI

✅ Supports PostCSS 8

  1. Update postcss-cli to >= 8.0.
  2. Add postcss dependency to your project.

JS API

✅ Supports PostCSS 8

  1. Just update postcss dependency.
  2. If you have custom plugins you may want to update them to avoid warning. See PostCSS 8.0 Migration Guide for Plugin Developers.

Gulp

✅ Supports PostCSS 8

  1. Update gulp-postcss to >= 9.0.
  2. Add postcss dependency to your project.

Grunt

✅ Supports PostCSS 8

  1. Move to @lodder/grunt-postcss >= 3.0.
  2. Add postcss dependency to your project.

Gatsby

✅ Supports PostCSS 8

  1. Update to gatsby-plugin-postcss >= 3.0.
  2. Add postcss dependency to your project.

Next.js

✅ Supports PostCSS 8

  1. Update to Next.js 10.

Parcel

✅ Supports PostCSS 8

  1. Update to Parcel 2 nightly pre-release yarn add parcel@nightly.
  2. Add postcss dependency to your project.

Rollup

✅ Supports PostCSS 8

  1. Update to rollup-plugin-postcss 4.0.
  2. Add postcss dependency to your project.

Nuxt.js

✅ Supports PostCSS 8

  1. Update to nuxt ≥2.15.3.
  2. Use nuxt/postcss8 module.

Create React App

✅ Supports PostCSS 8

  1. Update to create-react-app ≥3.0.

For now, you need to avoid using PostCSS 8 plugins.

Clone this wiki locally