Hi,
I’m very new to app development, so I’m just learning through Ionic. I’m currently going through the documentation. I’ve set up the environment and even fixed the EACCES error yesterday. However, when I proceeded to start with the “practice” angular app tutorial today, and I typed in “ionic start”, I got the message that the command “ionic” cannot be found.
So, do I have to run this code, npm install -g @ionic/cli, every time I re-open visual studio code and want to continue with a project?
Thank you!
How to proceed is highly dependent on your development OS environment.
Oh ok, do you mind please expanding on that? How do I know what my development OS environment is?
Thank you so much!
Well, likely it’s one of Windows, MacOS, or Linux. That would be a good place to start. For Windows, I would suggest installing nvm-windows. For the other two, ordinary nvm. Those should make these sorts of problems go away.
Thank you so much! Ok, so I do have MacOS, and I’ve installed nvm using the instructions in that link. I’ve done that twice now and if I type in “ionic start” right after installing nvm, it works. But, if I close the visual studio code window for the day and go back to it the next day, then I would have to install nvm again. I imagined I only had to install it once and I should be able to start or continue any ionic project. Do I have to install nvm every time I want to continue with a project?
No. It should have added bits to your shell initialization files so that it simply works every time you log in. I must say, however, that I’ve never used Visual Code, so somebody else may have to chime in on that.
Ok, thank you so much for clarifying! I just wanted to make sure that it should have been installed once, so I can investigate what’s going on with visual studio code.