Maxim Rudnev
Maxim Rudnev

Reputation: 1

Different versions of react-scripts in package.json and "npm view react-scripts version" - how can it be?

package.json in my project has [email protected]

I installed packages by "npm i", and when i put command "npm view react-scripts version" - I get version 5.0.1

Why? What have I done wrong?

PS C:\Users\admin\source\repos\eventsystem\EventSystem\ClientApp> npm view react-scripts version
5.0.1
PS C:\Users\admin\source\repos\eventsystem\EventSystem\ClientApp> npm list -g
C:\Users\admin\AppData\Roaming\npm
+-- [email protected]
`-- [email protected]

Upvotes: 0

Views: 595

Answers (1)

ram praveen
ram praveen

Reputation: 1

npm view "package"

Will show the package details. For now, you specified the version of the "react-scripts". It'll get the latest version of that package.

In your package, You're getting the install version of yours.

If you know more about npm-view. More https://docs.npmjs.com/cli/v10/commands/npm-view

Upvotes: 0

Related Questions