I have some npm dependencies that are showing missing in visual studio solutions. I added the dependencies to my package json file but some of my dependencies are showing missing error ex: express, typescript, and react dom.
CodePudding user response:
Just by adding them in package.json will not work. You need to install them to your environment.
- Open your terminal
- move to the folder where you have your project setup
- Type
npm install package_name
and hit enter
If the packages are already present in dependencies in package.json
Just type npm install
in your terminal it will install all the packages that are there in package.json
CodePudding user response:
I can see there is a package.json
file inside your project folder, Just run npm install
inside your project folder. So that all the packages and dependencies will automatically be installed inside your project.
If the problem still persist, Then your package.json
file might not contain those packages which you should install manually like below,
npm install express
npm install -g typescript
npm install react react-dom