I have started to explore the Node.js and wrote many demo web application, to understand the flow of Node.js, Express.js, jade, etc..
But one thing I came across recently, is the statement "use strict" as the first line inside every function and every .js file.
How exactly is it is interpreted by Node.js?
"use strict";Basically it enables the strict mode.
As per your comments you are telling some differences will be there. But it's your assumption. The Node.js code is nothing but your JavaScript code. All Node.js code are interpreted by the V8 JavaScript engine. The V8 JavaScript Engine is an open source JavaScript engine developed by Google for Chrome web browser.
So, there will be no major difference how
"use strict";is interpreted by the Chrome browser and Node.js.Please read what is strict mode in JavaScript.
For more information:
ECMAScript 6:
ECMAScript 6 Code & strict mode. Following is brief from the specification:
Additionally if you are lost on what features are supported by your current version of Node.js, this node.green can help you (leverages from the same data as kangax).