The following JS:  (function() {   "use strict";    $("#target").click(function(){     console.log("clicked");   });  }());   Yields:  test.js: line 5, col 3, '$' is not defined.   When linted using JSHint 0.5.5.  Any...
In my project we have some global variables that work as containers:  MyProject.MyFreature.someFunction = function() { ... }   So then I use that script across the site and JSLint / JSHint complains about that:     'MyProject' is not defined...
I'm using Gulp in my small project in order to run tests and lint my code. When any of those tasks fail, Gulp always exits with return code 0. If I run jshint by hand, it exits with non-zero code as it should.  Here's my very simple gulpfile....
JavaScript programs can be checked for errors in IDEs or using online web apps but I'm looking for a way to detect syntax errors alone.  I've tried JSLint and JSHint and looked at their options but I haven't been able to find a combinatio...
We're going through refactoring the code on a very large site. I would like to enforce linting on any files that get changed, but ignore the rest (as many of them will end up being removed so it's a waste of time to tidy them up).  I would li...
So, was the whole day working on our new FE workflow, the main idea is to run a few tasks through a watcher, we will have our IDE's and a window with the browsers getting refreshed each time something change (scss, js, html, etc).  So, we wont se...
How do I pass global config to jshint? I didn't find the answer in the documentation.  My config file:  >type tests\jshint_options.js /*jshint globalstrict:true */   This is what I've tried so far:  >jshint myfile.js --config=tests\jshi...
I've been struggling with VSCode and JSHint to find out a way to get rid of this syntax highlighting. It seems like JSHint is not able to recognise Async/Await syntax.  Here you can find a screenshot of what I'm talking about.     My JSHint v...
jslint can check indent by run 'jslint --indent 4 test.js', but I don't get it work in jshint. I do it as the follow steps.   install jshint through "npm install -g jshint" edit ~/.jshintrc, my jshintrc looks like {..., "inden...
I'm new to javascript programming (and scripting languages in general), but I've been using JS Lint to help me when I make syntax errors or accidentally declare a global variable.  However, there is a scenario that JS Lint does not cover, whi...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.