Skip to content

Commit

Permalink
gulp build system
Browse files Browse the repository at this point in the history
  • Loading branch information
arshaw committed Aug 8, 2016
1 parent 607bfaf commit b82f43d
Show file tree
Hide file tree
Showing 26 changed files with 935 additions and 763 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
build/temp
tmp
dist

# npm modules
Expand Down
22 changes: 22 additions & 0 deletions .jscs.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@

module.exports = {
requireCurlyBraces: [ 'if', 'else', 'for', 'while', 'do', 'try', 'catch' ],
requireSpacesInFunctionExpression: { beforeOpeningCurlyBrace: true },
disallowSpacesInFunctionExpression: { beforeOpeningRoundBrace: true },
//disallowSpacesInsideParentheses: true, // can't handle `something( //`
requireSpacesInsideObjectBrackets: 'all',
disallowQuotedKeysInObjects: 'allButReserved',
disallowSpaceAfterObjectKeys: true,
requireCommaBeforeLineBreak: true,
requireOperatorBeforeLineBreak: [ '?', '+', '-', '/', '*', '=', '==', '===', '!=', '!==', '>', '>=', '<', '<=' ],
requireSpacesInConditionalExpression: true,
requireSpaceAfterComma: true,
disallowSpaceBeforeComma: true,
requireSpaceBeforeDestructuredValues: true,
disallowSpaceAfterPrefixUnaryOperators: [ '++', '--', '+', '-', '~', '!' ],
disallowSpaceBeforePostfixUnaryOperators: [ '++', '--' ],
disallowKeywords: [ 'with' ],
disallowMultipleLineStrings: true,
requireDotNotation: true,
requireParenthesesAroundIIFE: true
};
13 changes: 13 additions & 0 deletions .jscs.strict.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@

var baseConfig = require('./.jscs');

module.exports = Object.assign({}, baseConfig, {
// more restrictions.
// we eventually want these to apply to all other code too.
requireSpaceAfterKeywords: [ 'if', 'else', 'for', 'while', 'do', 'switch', 'return', 'try', 'catch' ],
requireSpacesInsideArrayBrackets: 'all',
requireKeywordsOnNewLine: [ 'else', 'catch' ],
disallowTrailingWhitespace: true,
validateQuoteMarks: '\'',
maximumLineLength: 120
});
25 changes: 25 additions & 0 deletions .jshint.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

module.exports = {
browser: true,
globals: {
// `false` means read-only
define: false,
exports: false,
module: false,
require: false,
moment: false,
jQuery: false
},
es3: true,
bitwise: true,
curly: true,
//forin: true, // couldn't handle `for (k in o) if (!`
freeze: true,
immed: true,
noarg: true,
smarttabs: true,
trailing: true,
eqnull: true,
'-W032': true, // Unnecessary semicolon. (lumbar's ;;)
'-W008': true // A leading decimal point can be confused with a dot (ex: .5) // TODO: think about enabling!
};
Loading

0 comments on commit b82f43d

Please sign in to comment.