I'm beginner to MEAN stack, while studying NodeJS, I'm came up with the following statement that's taking my mind
but what exactly does it mean by
and if it's built on Chrome's JS V8 Engine, why does it works on Firefox as well?
nr: #1 dodano: 2016-12-30 18:12
The statement that NodeJS is built on top of this engine means that it uses this interpreter for it's own thing, so it can also be used on the server, not just in the desktop environment (like in Google Chrome).
NodeJS is a separate application that you can communicate with over the internet, it's like Apache, Nginx or similar, but it's not used for one thing only (like the ones mentioned), but it's mostly used for making web-server like applications.
nr: #2 dodano: 2016-12-30 18:12
Node uses the same JS "engine" that runs chrome.
An engine in this case, is a piece of software that compiles, or "translates" your JS code into machine code; or the 0s and 1s your computer can understand.
When you run a node server, it runs on a machine that acts as a server. The code is not run on the user's machine at all; hence it doesn't matter which browser is used to view your content.
nr: #3 dodano: 2016-12-30 18:12
nr: #4 dodano: 2016-12-30 18:12
MEAN stack, reorganized from back to front:
- MongoDB: data persistence, stores data for later retrieval
- Node.js: web application server, responds to requests from clients
- Express: web application framework, reduces Node boilerplate
- Angular.js: browser framework
So Node.js does not "work on Firefox" (it doesn't work on Google Chrome either): its a server-side technology. Think of it as a replacement for Python/Ruby/Java in that role. So it can/does respond to requests from all sorts of clients (like Google Chrome and Firefox).
nr: #5 dodano: 2016-12-30 18:12
Ok let's get through this:
nr: #6 dodano: 2016-12-30 18:12
V8 was open sourced by Google. The creator of Node, Ryan Dahl, modified the source code so that V8 could be used outside of Chrome and inside an operating system like Linux or MacOS. That is what is meant by your first quote.
nr: #7 dodano: 2016-12-30 19:12
So it's independent of browser and platform.