简体   繁体   中英

Does Running Node Locally Differ From Installing Node on the Web Server?

I'm wondering in principle how node.js works on a website that's running node code. I'm new to programming but I did manage to get node installed to practice with Angular and some Nodeschool stuff, however I don't think this is actually the whole story because the web server needs to have node and npm (maybe nvm) all installed in order to actually use any node code. Or am I misunderstanding how node works?

I guess I'm really looking for an understanding of the whole application of the node framework; what am I actually doing by running a practice program like the "Tour of Heros" Angular tutorial on my local machine, just testing it locally right? Because if I actually wanted it on my website I'd need to install node there and then run the framework on the server, from what I can gather...

Thanks for your time! I hope I made my confusion clear enough.

Angular tutorial by Google "Tour of Heroes"

Node and JavaScript are different. Node provides a runtime environment enables JavaScript code to be executed outside browser. It provides various native libraries and event loop allowing main thread of execution to perform asynchronous operations.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM