21
12

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

[TailwindCSS] Error: PostCSS plugin tailwindcss requires PostCSS 8.

Posted at

エラー発生状況

Gatsbyで制作を進めていたサイトにTailwindを導入しようとした(21年1月時点)

PostCSS plugin postcss-nested requires PostCSS 8.
Migration guide for end-users:
https://github.com/postcss/postcss/wiki/PostCSS-8-for-end-users

対処

一度アンインストールして、互換性ビルドを再インストール

npm uninstall tailwindcss postcss autoprefixer
npm install tailwindcss@npm:@tailwindcss/postcss7-compat @tailwindcss/postcss7-compat postcss@^7 autoprefixer@^9

原因

PostCSS8対応が追いついていないという感じでしょうか。
サポートされたらlatest使ってくれとのこと。

参照

PostCSS 7 compatibility build
PostCSS plugin postcss-nested requires PostCSS 8 #2799

21
12
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
21
12

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?