Skip to content

Instantly share code, notes, and snippets.

@microadam
Created April 24, 2014 19:46
Show Gist options
  • Save microadam/11267121 to your computer and use it in GitHub Desktop.
Save microadam/11267121 to your computer and use it in GitHub Desktop.
Example .jscsrc
{ "excludeFiles":
[ "node_modules/**"
, "coverage"
]
, "requireLineFeedAtFileEnd": true
, "disallowMultipleLineBreaks": true
, "requireMultipleVarDecl": true
, "disallowEmptyBlocks": true
, "disallowSpaceAfterObjectKeys": true
, "disallowCommaBeforeLineBreak": true
, "disallowTrailingWhitespace": true
, "requireCapitalizedConstructors": true
, "requireSpacesInsideObjectBrackets": "all"
, "requireSpacesInsideArrayBrackets": "all"
, "validateLineBreaks": "LF"
, "requireSpaceBeforeBinaryOperators": [ "+", "-", "/", "*", "=", "==", "===", "!=", "!==" ]
, "requireSpaceAfterBinaryOperators": [ "+", "-", "/", "*", "=", "==", "===", "!=", "!==" ]
, "requireSpaceAfterKeywords": [ "if", "else", "for", "while", "do", "switch", "try", "catch" ]
, "disallowLeftStickedOperators": [ "?", "+", "/", "*", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<=" ]
, "disallowRightStickedOperators": [ "?", "+", "/", "*", ":", "=", "==", "===", "!=", "!==", ">", ">=", "<", "<=" ]
, "disallowSpaceAfterPrefixUnaryOperators": [ "++", "--", "+", "-", "~", "!" ]
, "disallowSpaceBeforePostfixUnaryOperators": [ "++", "--" ]
, "requireSpaceBeforeBinaryOperators": [ "+", "-", "/", "*", "=", "==", "===", "!=", "!==" ]
, "requireSpaceAfterBinaryOperators": [ "+", "-", "/", "*", "=", "==", "===", "!=", "!==" ]
, "disallowKeywordsOnNewLine": [ "else" ]
, "requireSpacesInFunctionExpression": { "beforeOpeningCurlyBrace": true }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment