Using JSLint in Notepad++

I have managed to get two lint programs to run using the notepad++’s NppExec Plugin. The NppExec plugin is usually installed by default and can be found under plugins -> NppExec. (Using NppExec 0.3 RC1 and Notepad++ 5.1+). 1) JSLint first download the WSH version of jslint from http://www.jslint.com. Modify the last part of the … Read more

Why is JSLint wanting me to use double quotes instead of single quotes? Expected ‘”‘ and instead saw ”’

The 2016-02-07 version of JSLint changed to prefer double quotes over single quotes. Douglas Crockford, developer of JSLint and influential developer for JavaScript and JSON, provided this rationale: When I first met JavaScript, it [sic] was surprised that it had the two kinds of quotes, and I tried to make sense of it, using single … Read more

Getting Facebook’s react.js library JSX syntax to play nicely with jslint?

I tried to follow Dustin’s and STRML’s advice on this thread, and here’s what worked best for me. Development Setup I use Sublime Text with SublimeLinter + SublimeLinter-jshint + SublimeLinter-jsxhint. These are very nice plugins that let me see mistakes when I save the file, both for JS and JSX files: These plugins respect your … Read more

Have jshint ignore certain files when building Twitter Bootstrap

So there is an option to ignore files in jshint, but it’s not set within .jshintrc but rather a separate file .jshintignore, which makes sense. However, while jshint will look for .jshintrc in your project’s subdirectories, .jshintignore needs to be in the project root. So with Twitter Bootstrap, .jshintrc is in /js while .jshintignore needs … Read more

Angular-cli : Using ng lint

Updated answer for Angular CLI v6.x, 7.x, 8.x: ng lint <project-name> –fix where <project-name> is “name:” from package.json — answer for Angular CLI v1.x — ng lint -fix — Original answer below — To have tslint autofix many errors run the following in the root of your code. Obviously it can only autofix simpler issues … Read more

Where can I find a list of JSHint numeric error codes?

The best place to look for things like that is the source (which is available on GitHub). The file you’re looking for is messages.js (versions: current release (2.9.5, 2017-06-22), master branch, 2.1.4 (source for the code below)): var warnings = { W001: “‘hasOwnProperty’ is a really bad name.”, W002: “Value of ‘{a}’ may be overwritten … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)