1
0

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 1 year has passed since last update.

【Next.js】@types/reactが認識されない場合の対応方法

Posted at

概要

@types/react 18.0.2 をインストールしたが認識されない事象があったので対処方法をまとめる

It looks like you're trying to use TypeScript but do not have the required package(s) installed.

Please install @types/react by running:

        yarn add --dev @types/react

If you are not trying to use TypeScript, please remove the tsconfig.json file from your package root (and any TypeScript files in your pages directory).

@types/reactをダウングレードする

issuesの通りだが18.0.2にバグがあるらしくダウングレードすることで正常化するとのこと

npm install --save-dev @types/react@18.0.1
1
0
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
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?