Skip to content

Instantly share code, notes, and snippets.

@tnguyen14
Last active August 29, 2015 14:13
Show Gist options
  • Save tnguyen14/8d15aaa350f72ff7be27 to your computer and use it in GitHub Desktop.
Save tnguyen14/8d15aaa350f72ff7be27 to your computer and use it in GitHub Desktop.
code linting configs
# EditorConfig is awesome: http://EditorConfig.org
# top-most EditorConfig file
root = true
# Unix-style newlines with a newline ending every file
[*]
end_of_line = lf
insert_final_newline = true
charset = utf-8
indent_style = tab
indent_size = 4
trim_trailing_whitespace = true
# Matches the exact files either package.json or .travis.yml
[{package.json,.travis.yml}]
indent_style = space
indent_size = 2
{
"disallowKeywordsOnNewLine": ["else"],
"disallowMixedSpacesAndTabs": true,
"disallowNewlineBeforeBlockStatements": true,
"disallowSpaceAfterObjectKeys": true,
"disallowSpacesInsideArrayBrackets": "all",
"disallowSpacesInsideObjectBrackets": "all",
"disallowSpacesInsideParentheses": true,
"disallowTrailingWhitespace": true,
"disallowTrailingComma": true,
"excludeFiles": ["node_modules/**"],
"requireBlocksOnNewline": 1,
"requireCommaBeforeLineBreak": true,
"requireSpaceAfterBinaryOperators": true,
"requireSpaceAfterKeywords": ["if", "else", "for", "while", "do", "switch", "return", "try", "catch"],
"requireSpaceBeforeBinaryOperators": true,
"requireSpaceBeforeBlockStatements": true,
"requireSpacesInAnonymousFunctionExpression": {
"beforeOpeningRoundBrace": true,
"beforeOpeningCurlyBrace": true
},
"requireSpacesInConditionalExpression": true,
"requireSpacesInNamedFunctionExpression": {
"beforeOpeningCurlyBrace": true
},
"validateQuoteMarks": "'"
}
{
"camelcase": true,
"curly": true,
"eqeqeq": true,
"undef": true,
"unused": true,
"browser": true,
"strict": true,
"browserify": true,
"node": true
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment