V
V
Vasiliy2015-03-22 17:23:49
JavaScript
Vasiliy, 2015-03-22 17:23:49

JSLint good or bad!???

3f09ed80666542f398e46ad254971acb.jpg
In general, I don’t know what to do ... here and so you are trying to write code ... so it also gives you errors during validation ...
in short, here is a code example ...

function say(){

    return function (name){
    return greet + " " + name;
    };
}

var greet = 'Hello';
var en = say();
console.log(say("John"));
console.log(say("Martin"));

and here is the fucking validator www.jslint.com
How to write such code without errors??

Answer the question

In order to leave comments, you need to log in

3 answer(s)
N
Nikita, 2018-02-05
@Rema1ns

And what is there to explain?) look at the code, there is svg, which changes its path when hovering over
5a77c5e7cd85e386069638.jpeg

I
index0h, 2015-03-22
@VasiliySidorenko63

Do not write kaku and everything will be ok, in the same place in the output it is written what is wrong. And this is not a "fucking validator", but a VERY effective system for straightening crooked arms.

M
Mikhail Goryachkin, 2015-03-22
@abaddon65

Well, you have everything written as it should:

/*global console*/
var greet = 'Hello';
function say() {
    "use strict";
    return function (name) {
        return greet + " " + name;
    };
}

var en = say();
console.log(say("John"));
console.log(say("Martin"));

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question