Answer the question
In order to leave comments, you need to log in
Node.js includes all JS, in the sense that any stuff that can be found in the JS documentation can be used in Node.js code?
Given that Node.js is the back end.
Answer the question
In order to leave comments, you need to log in
No.
Only
https://developer.mozilla.org/en-US/docs/Web/JavaS...
+
https://nodejs.org/dist/latest/docs/api/
But there are polyfills for some browser APIs - look individually under the project.
Think of it like this:
There 's javascript - it's a tool language - it's the same for nodejs , browsers , and can be used in other environments as well. It's just a language that you use to interact with the environment-provided interfaces ( APIs ). Along with the language come the basic types ( Number, String, Boolean, null, undefined, Date ).
There is an API , which is a certain set of classes, modules and methods that are provided by a specific environment. Nodejs has its own set of modules, and browsers have their own set of classes, methods, and global objects. It turns out that you can write some code that will work onnodejs and in browsers if the code does not affect the . For example, if you are writing a game, then you can abstract the game logic from the API and write it once - and it will work on both backend and frontend . This way it will be possible to run a simulation of the player's game on the backend . Or you have an application where some data structures are transferred to the server and you can write only once classes that work with them (parsing, etc.) and use them right away and there and there.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question