Reputation: 351
When I click on useState, I get wrong import:
import { useState } from "react/cjs/react.development";
I need to click and get:
import { useState } from "react";
How to change this?
Upvotes: 3
Views: 929
Reputation: 46
I faced same problem. It suddenly happened few days ago to me, don't know what exactly gone wrong with my project.
But, I found temporary solution and using it.
install @types/react
into your project.
solution from: https://github.com/microsoft/vscode/issues/141385
Upvotes: 3