cheatsheets/jshint.md

619 B

title layout
Jshint default

Relaxing

/* expr: true */
production && minify = true;

/* loopfunc: true */
for (i=0; i<10; x++) {
  (function(i) {
  })(i);
}

/* sub: true */
process.env['name_here'];

Enforcement

/* es3: true (legacy IE compatibility) */
a.default = function() { ... };
array = [ 1, 2, 3, ];

Environments

browser /* window, document, ... */
node    /* module, exports, console, process, ... */
jquery  /* jQuery, $ */

Also see