Skip to content

Commit 892c49e

Browse files
committed
Update the “serve” task
1 parent 39ab647 commit 892c49e

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

gulpfile.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -251,10 +251,10 @@ gulp.task(`build`, [
251251
/**
252252
* SERVE
253253
*
254-
* Used for development only, this task…
254+
* Used for development, this task…
255255
*
256256
* — compiles CSS via Sass,
257-
* — concatenates one or more JavaScript files into a single file,
257+
* — transpiles JavaScript files into ES6,
258258
* — lints JavaScript, and
259259
* — validates HTML.
260260
*
@@ -266,15 +266,15 @@ gulp.task(`build`, [
266266
* Thus, CSS and JS are served from a temp folder (temp), while un-processed files,
267267
* such as fonts and images, are served from the development source folder (dev).
268268
*
269-
* If a JavaScript file is changed, all JavaScript files are rebuilt, the resulting
270-
* file is linted, and the browser reloads.
269+
* If a JavaScript file is changed, all JavaScript files are linted, re-transpiled,
270+
* and the browser reloads.
271271
*
272272
* If a Sass file is changed, a re-compilation of the primary CSS file is generated,
273273
* and the browser reloads.
274274
*
275275
* Finally, changes to images also trigger a browser reload.
276276
*/
277-
gulp.task(`serve`, [`compileCSSForDev`, `transpileJSForDev`, `lintJS`, `validateHTML`], function () {
277+
gulp.task(`serve`, [`compileCSSForDev`, `lintJS`, `transpileJSForDev`, `validateHTML`], function () {
278278
browserSync({
279279
notify: true,
280280
port: 9000,
@@ -289,7 +289,7 @@ gulp.task(`serve`, [`compileCSSForDev`, `transpileJSForDev`, `lintJS`, `validate
289289
}
290290
});
291291

292-
gulp.watch(`dev/scripts/*.js`, [`transpileJSForDev`, `lintJS`])
292+
gulp.watch(`dev/scripts/*.js`, [`lintJS`, `transpileJSForDev`])
293293
.on(`change`, reload);
294294

295295
gulp.watch(`dev/styles/**/*.scss`, [`compileCSSForDev`])

0 commit comments

Comments
 (0)