enter image description herewhen trying to retrieve the information about my Angular package, i got the below both for Angular version, one package and typescript :
Related
I've been updating the version of an angular version, I used the angular update guide, and used ng update #angular/core#11 #anuglar/cli#11, for the most part I was able to get it all done but when I try and do ng server, I get this error Picture of terminal error
Here is my Package.json
Packag.json
I have tried deleteing node modules and packag-lock and doing npm install, but I still get the same error when doing ng serve.
I know that my #angular/material isn't the same version as the rest of my angular, when I update my material version it just causes more and more errors.
Your node modules are probably still cached. Try the following command
npm cache clean --force
then do npm install again
I've been following this Angular guide (https://update.angular.io/?l=3&v=8.2-12.0) to upgrade the Angular version of my project from 9 to 10 (12 ultimately) but when I execute ng --version command it still shows 9.1.13.
I have provided links to two images. The first one showing the update from Angular version 9 to 10 and the second showing the current Angular version of the project.
Upgrade Angular Version
Current Angular Version
Anyone know what may be the issue?
If you are running ng --version command outside of your project folder and you have global #angular/cli installed on your machine, so maybe it's normal.
You can have a specific #angular/cli version installed for your project and another global installed on your PC.
Try to run npm i -g #angular/cli#12.2.18 and then run your ng --version
It will install a global #angular/cli#12.2.18 on your PC. No matter on witch folder you are.
I have installed Node JS and tried running angular with both the LTS and the Latest versions of NodeJS. I have installed angular too in the cmd. But whenever I am trying to run angular codes or trying to cheek the version of Angular. I am getting this error.
enter image description here
I am not able to install latest version of react. Actually I installed a particlar version after appending # , after that what ever I am doing it is not working. even I unistalled nodejs completely. still it is not working.
npm react --version
6.14.15
Then I ran this
npm install --save react#latest
After that version is still coming same.
npm react --version
6.14.15
After that I uninstalled react using below
npm uninstall -g create-react-app
I also did
npm uninstall react
and then checked the version. it is still coming same.
I followed onw blog and tried below. still it dint work.
npm install react-scripts#4.0.0 react#17.0.0 react-dom#17.0.0
and installed react again. still it is giving same version.
Could you please help me on the same.
Is there any to remove it completely from the system?
Let understand the diff between react and create react app.
React is a js library for creating user interfaces but and create react app is a cli tool that help us to create the files template for a react project and both are totally different npm packages.
The create react app doesn't depend on react so it doesn't install the required version of react.
If you want to upgrade your react library you have to install react
npm i -g react#latest
I am trying to define validation which check the node and cli version with specified version before going to install package.json dependencies.
Example: Suppose when I started my angular project the node and cli version was 5.2.1 and now they are updated 5.2.6 or 5.3.* but I don't want to run my app on updated version so how can I show alert/error message and exit that user who are going to install the app and there package dependencies