Skip to content

Instantly share code, notes, and snippets.

@markelog
Created October 1, 2014 18:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save markelog/bf9059f816d366c552c8 to your computer and use it in GitHub Desktop.
Save markelog/bf9059f816d366c552c8 to your computer and use it in GitHub Desktop.
new approach to jscs config
{
codeBlocks: {
curlyBraces: {
operators: true || [],
expect: [ "return", "break" ]
},
newlineBefore: {
statements: true,
expect: [ "for..of", "for" ]
}
},
binaryOperators: {
spacesAround: [
"=", "+=", "-=", "*=", "/=", "%=", "<<=", ">>=", ">>>=",
"&=", "|=", "^=", "+=",
"+", "-", "*", "/", "%", "<<", ">>", ">>>", "&",
"|", "^", "&&", "||", "===", "==", ">=",
"<=", "<", ">", "!=", "!=="
],
noSpacesAround: [ ",", ":" ],
},
// or
binaryOperators: {
spacesAround: true || {
value: [] || true,
except: []
},
noSpacesAround true || {
value: [] || true,
except: []
},
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment