Skip to content

Instantly share code, notes, and snippets.

@silverbux
Last active August 29, 2015 14:26
Show Gist options
  • Save silverbux/4d1845bfd3c5c16ba4ac to your computer and use it in GitHub Desktop.
Save silverbux/4d1845bfd3c5c16ba4ac to your computer and use it in GitHub Desktop.
jscsrc file
{
    "requireCurlyBraces": [
        "if",
        "else",
        "for",
        "while",
        "do",
        "try",
        "catch"
    ],
    "requireOperatorBeforeLineBreak": true,
    "requireCamelCaseOrUpperCaseIdentifiers": true,
    "maximumLineLength": {
      "value": 80,
      "allowComments": true,
      "allowRegex": true
    },
    "validateIndentation": 2,
    "validateQuoteMarks": "'",
    "disallowMultipleLineStrings": true,
    "disallowMixedSpacesAndTabs": true,
    "disallowTrailingWhitespace": true,
    "disallowSpaceAfterPrefixUnaryOperators": true,
    "disallowMultipleVarDecl": true,
    "disallowKeywordsOnNewLine": ["else"],
    "requireSpaceBeforeBinaryOperators": [
        "=", "+=", "-=", "*=", "/=", "%=", "<<=", ">>=", ">>>=",
        "&=", "|=", "^=", "+=",

        "+", "-", "*", "/", "%", "<<", ">>", ">>>", "&",
        "|", "^", "&&", "||", "===", "==", ">=",
        "<=", "<", ">", "!=", "!=="
    ],
    "requireSpaceAfterBinaryOperators": true,
    "requireSpacesInConditionalExpression": true,
    "requireSpaceBeforeBlockStatements": true,
    "requireSpacesInForStatement": true,
    "requireLineFeedAtFileEnd": true,
    "disallowSpacesInsideObjectBrackets": "all",
    "disallowSpacesInsideArrayBrackets": "all",
    "disallowSpacesInsideParentheses": true,
    "disallowMultipleLineBreaks": true,
    "disallowNewlineBeforeBlockStatements": true,
    "disallowKeywords": ["with"],
    "disallowSpacesInCallExpression": true,
    "requireSpaceBeforeObjectValues": true,
    "requireCapitalizedConstructors": true,
    "requireDotNotation": true,
    "validateParameterSeparator": ", ",
    "requireSpaceAfterKeywords": [
      "if",
      "else",
      "for",
      "while",
      "do",
      "switch",
      "return",
      "try",
      "catch",
      "function"
    ]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment