Whitespace Around

Checks for whitespace around a token.


Configuration

{
    "type": "WhitespaceAround",
    "props": {
        "severity": "WARNING",
        "tokens": [ "=", "+" ]
    }
}

Valid

    var test = [];
    test2 = 1 + 2;

Invalid

    var test =[];
    test2 = 1+ 2;

Warning No whitespace around =


Warning No whitespace around +