JSLint: I can't calm it down in a space in the expression "var"

I use JSLint and have a huge code library that is 100% pure JSLint. Starting from 1.20.2011, JSLint reports whitespacing error errors for each var statement. Take, for example, this (now hollowed out) function:

var dateStrFromTimestamp;
dateStrFromTimestamp = function (t) {
    "use strict";
    var a, d;
    d = new Date(t * 1000);
    a = [];
};

JSLint Reports:

Problem at line 1 character 5: Expected 'dateStrFromTimestamp' at column 3, not column 5.

    var dateStrFromTimestamp;

Problem at line 4 character 7: Expected 'a' at column 5, not column 7.

    var a, d;

How should I write my code? If I follow this recommendation, I will have to remove the space after the keyword "var" - but this cannot be. So, the current version of JSLint buggy? Or am I currently blind to something obvious?

+3
source share
2 answers

, . , Shift +, JS , , , , .

+2

, , , JSLint , 4 .

0

Source: https://habr.com/ru/post/1786901/


All Articles