Question

As is fairly common these days, I use AMD modules to organize my JS. So I have a .jshintrc configured in each project accordingly:

{
    "predef": [
        "define",
        "require"
    ]
}

On the command line, running jshint gives clear output. However Codekit seems to be ignoring the jshint when it runs, complaining about 'define' etc.

How can I make Codekit respect a .jshintrc file?

Était-ce utile?

La solution

Custom Globals is a CSV list that is used for both JSHint and JSLint.

It is located here:

CodeKit.app[Select Your Project]Project Settings / [Gear Icon]Syntax CheckersCustom Globals

Yours would look like this:

CodeKit - loading= Project Settings -> Syntax Checkers -> Custom Globals ">

I tested it with "app, angular" and it worked like a charm.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top