commit 798a101cfe2e5f673486504c355c6264658ddaed
parent 999dbac5d62c7a82322811224080ece4fefa886e
Author: Konstantin Tarkus <hello@tarkus.me>
Date: Fri, 27 Feb 2015 23:09:32 +0300
Add JSCS config file
Ref #71
Diffstat:
4 files changed, 17 insertions(+), 5 deletions(-)
diff --git a/.jscsrc b/.jscsrc
@@ -0,0 +1,8 @@
+{
+ "preset": "google",
+ "disallowSpacesInAnonymousFunctionExpression": null,
+ "validateLineBreaks": "LF",
+ "validateIndentation": 2,
+ "excludeFiles": ["build/**", "node_modules/**"],
+ "esprima": "esprima-fb"
+}
diff --git a/gulpfile.js b/gulpfile.js
@@ -40,7 +40,9 @@ var browserSync;
gulp.task('default', ['sync']);
// Clean output directory
-gulp.task('clean', del.bind(null, ['.tmp', 'build/*', '!build/.git'], {dot: true}));
+gulp.task('clean', del.bind(
+ null, ['.tmp', 'build/*', '!build/.git'], {dot: true}
+));
// 3rd party libraries
gulp.task('vendor', function() {
@@ -135,7 +137,7 @@ gulp.task('serve', ['build:watch'], function(cb) {
var server = (function startup() {
var child = cp.fork('build/server.js', {
- env: assign({ NODE_ENV: 'development' }, process.env)
+ env: assign({NODE_ENV: 'development'}, process.env)
});
child.once('message', function(message) {
if (message.match(/^online$/)) {
@@ -200,7 +202,8 @@ gulp.task('deploy', function() {
}
return gulp.src('build/**/*')
- .pipe($.if('**/robots.txt', !argv.production ? $.replace('Disallow:', 'Disallow: /') : $.util.noop()))
+ .pipe($.if('**/robots.txt', !argv.production ?
+ $.replace('Disallow:', 'Disallow: /') : $.util.noop()))
.pipe($.ghPages({
remoteUrl: 'https://github.com/{name}/{name}.github.io.git',
branch: 'master'
diff --git a/preprocessor.js b/preprocessor.js
@@ -10,7 +10,7 @@ module.exports = {
}
// Ignore all files within node_modules
if (filename.indexOf('node_modules') === -1) {
- return babel.transform(src, { filename: filename }).code;
+ return babel.transform(src, {filename: filename}).code;
}
return src;
}
diff --git a/webpack.config.js b/webpack.config.js
@@ -65,7 +65,8 @@ var config = {
},
{
test: /\.less$/,
- loader: 'style-loader!css-loader!' + AUTOPREFIXER_LOADER + '!less-loader'
+ loader: 'style-loader!css-loader!' + AUTOPREFIXER_LOADER +
+ '!less-loader'
},
{
test: /\.gif/,