You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
var fastMvpApiRouter = require('./fastmvpcore/routes/api');
ECMAScript 2015 introduced the let and const keywords for block-scope variable declaration. Using const creates a read-only (constant) variable.
The distinction between the variable types created by var and by let is significant, and a switch to let will help alleviate many of the variable scope issues which have caused confusion in the past.
Because these new keywords create more precise variable types, they are preferred in environments that support ECMAScript 2015. However, some refactoring may be required by the switch from var to let, and you should be aware that they raise SyntaxErrors in pre-ECMAScript 2015 environments.
This rule raises an issue when var is used instead of const or let.
Noncompliant Code Example
var color = "blue";
var size = 4;
The text was updated successfully, but these errors were encountered:
/app.js
var fastMvpApiRouter = require('./fastmvpcore/routes/api');
ECMAScript 2015 introduced the let and const keywords for block-scope variable declaration. Using const creates a read-only (constant) variable.
The distinction between the variable types created by var and by let is significant, and a switch to let will help alleviate many of the variable scope issues which have caused confusion in the past.
Because these new keywords create more precise variable types, they are preferred in environments that support ECMAScript 2015. However, some refactoring may be required by the switch from var to let, and you should be aware that they raise SyntaxErrors in pre-ECMAScript 2015 environments.
This rule raises an issue when var is used instead of const or let.
Noncompliant Code Example
var color = "blue";
var size = 4;
The text was updated successfully, but these errors were encountered: