diff --git a/.jshintrc b/.jshintrc index 0cd291c..24a40bc 100644 --- a/.jshintrc +++ b/.jshintrc @@ -17,5 +17,8 @@ "strict": true, "trailing": true, "smarttabs": true, - "white": true + "white": true, + "globals": { + "document": true + } } diff --git a/gulpfile.js b/gulpfile.js index f5b884b..7a856c8 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -26,18 +26,18 @@ gulp.task('browserSync', function() { }); gulp.task('react', function() { - return gulp.src('src/javascripts/templates/**/*.html') + return gulp.src('src/js/templates/**/*.html') .pipe(html2react()) - .pipe(gulp.dest('temp/javascripts/templates')); + .pipe(gulp.dest('temp/js/templates')); }); gulp.task('copy_js', function() { - var files = ['src/javascripts/**/*.js']; - return gulp.src(files).pipe(gulp.dest('temp/javascripts')); + var files = ['src/js/**/*.js']; + return gulp.src(files).pipe(gulp.dest('temp/js')); }); gulp.task('copy', ['copy_js'], function() { - var files = ['src/**/*', '!src/javascripts', '!src/javascripts/**/*']; + var files = ['src/**/*', '!src/js', '!src/js/**/*']; var DEST = 'dist'; return gulp.src(files).pipe(changed(DEST)).pipe(gulp.dest(DEST)); @@ -45,15 +45,15 @@ gulp.task('copy', ['copy_js'], function() { // using vinyl-source-stream: gulp.task('browserify', ['copy', 'react'], function() { - var bundleStream = browserify('./temp/javascripts/app.js').transform(debowerify).bundle(); + var bundleStream = browserify('./temp/js/app.js').transform(debowerify).bundle(); bundleStream - .pipe(source('./javascripts/app.js')) + .pipe(source('./js/app.js')) .pipe(gulp.dest('./dist/')); }); gulp.task('default', ['browserify', 'browserSync'], function() { gulp.watch('src/*.html', ['copy']); - gulp.watch('src/stylesheets/**/*', ['copy']); + gulp.watch('src/css/**/*', ['copy']); - gulp.watch('src/javascripts/**/*', ['browserify']); + gulp.watch('src/js/**/*', ['browserify']); }); diff --git a/src/index.html b/index.html similarity index 60% rename from src/index.html rename to index.html index ec59cdc..3bf1394 100644 --- a/src/index.html +++ b/index.html @@ -3,10 +3,11 @@
welcome to react
- +