I'd like to apply both JSHint and "use strict";
to my Node.js code, but when I do, JSHint complains:
$ jshint .
binfix.js: line 14, col 1, 'exports' is not defined.
binfix.js: line 24, col 1, 'exports' is not defined.
binfix.js: line 48, col 1, 'exports' is not defined.
use /*jshint node:true */
option.
@antonkovalyov Thanks again! All the warnings went away when I added "node": true
to my .jshintrc
!
I added this:
{
"node" : true
}
in .jshintrc file and it worked well for me. Thank you @mcandre and @valueof !
Most helpful comment
I added this:
in .jshintrc file and it worked well for me. Thank you @mcandre and @valueof !