How can I configure Web Essentials 2013 to ignore files?

后端 未结 4 722
执笔经年
执笔经年 2020-12-30 23:35

I have a fresh MVC 5.1 web app project in VS 2013 (Update 1) w/ Web Essential 2013 (latest as of today) installed. After building the project, Web Essentials scans for javas

4条回答
  •  旧时难觅i
    2020-12-31 00:03

    I had the same issue after installing KendoUI. It was basically impossible to run the project. I solved it by going to Web Essentials -> Edit global JSCS settings and adding:

    "excludeFiles": ["Scripts/kendo/*"]
    

    below the "excludeFiles": ["test/data/*.js"] entry.

    Now the .jscs.json file looks like this:

    {
    "requireCurlyBraces": ["if", "else", "for", "while", "do", "try", "catch"],
    "requireSpaceAfterKeywords": ["if", "else", "for", "while", "do", "switch", "return", "try", "catch"],
    "disallowLeftStickedOperators": ["?", "+", "-", "/", "*", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="],
    "disallowRightStickedOperators": ["?", "+", "/", "*", ":", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<="],
    "requireRightStickedOperators": ["!"],
    "requireLeftStickedOperators": [","],
    "disallowImplicitTypeConversion": ["string"],
    "disallowKeywords": ["with"],
    "disallowMultipleLineBreaks": true,
    "disallowKeywordsOnNewLine": ["else"],
    "excludeFiles": ["test/data/*.js"],
    "excludeFiles": ["Scripts/kendo/*"]
    "validateJSDoc": {
        "checkParamNames": true,
        "requireParamTypes": true
        }
    }
    

    Just replace the ["Scripts/kendo/*"] with whatever you want to exclude. Worked like a charm for me.  

提交回复
热议问题