When I used
yarn create next-app --typescript
to set up a TypeScript Next.js application with Yarn, everything seemed to be working fine with the command yarn run dev
. However, Visual Studio Code was not recognizing any of the yarn packages that were added.
https://i.sstatic.net/mSM8j.jpg
I attempted to resolve this issue by following the steps outlined in the official Yarn's Editor SDKs documentation. This involved running the following command:
yarn dlx @yarnpkg/sdks vscode
https://i.sstatic.net/V18tm.png
I then proceeded to select the appropriate TypeScript version as instructed.