From 75c8a8a6d85e447703bddf0998a5ec3f1818a3f9 Mon Sep 17 00:00:00 2001 From: Vladimir Pikul Date: Fri, 23 Aug 2019 16:25:11 +0300 Subject: [PATCH 1/2] babelify upgraded; deleted unnecessary dependencies --- package.json | 15 ++++++--------- tasks/browser-sync-server.js | 5 ++--- tasks/build-custom-js.js | 14 ++++++++++++-- 3 files changed, 20 insertions(+), 14 deletions(-) diff --git a/package.json b/package.json index 97eca61..dcd889f 100644 --- a/package.json +++ b/package.json @@ -19,16 +19,15 @@ }, "homepage": "https://github.com/justcoded/web-starter-kit", "devDependencies": { - "babel-eslint": "^10.0.1", - "babel-preset-es2015": "^6.24.0", - "babelify": "^7.3.0", + "@babel/core": "^7.5.5", + "@babel/preset-env": "^7.5.5", + "babelify": "^10.0.0", "browser-sync": "^2.18.0", - "browserify": "^14.0.0", + "browserify": "^16.5.0", "del": "^3.0.0", - "eslint": "^5.11.1", "eslint-config-airbnb-base": "^13.1.0", "eslint-plugin-import": "^2.14.0", - "files-exist": "^1.0.2", + "files-exist": "^1.1.0", "gulp": "^4.0.0", "gulp-autoprefixer": "^4.0.0", "gulp-concat": "^2.6.1", @@ -36,6 +35,7 @@ "gulp-cssnano": "^2.1.2", "gulp-debug": "^3.1.0", "gulp-eslint": "^5.0.0", + "gulp-file-include": "^2.0.1", "gulp-group-css-media-queries": "^1.2.0", "gulp-htmlhint": "^0.3.1", "gulp-if": "^2.0.2", @@ -46,12 +46,9 @@ "gulp-sass": "^4.0.2", "gulp-sourcemaps": "^2.4.1", "gulp-uglify": "^3.0.0", - "gulp-util": "^3.0.8", - "gulp-file-include": "^2.0.1", "htmlhint-stylish": "^1.0.3", "node-notifier": "^5.0.2", "path": "^0.12.7", - "vinyl-buffer": "^1.0.0", "vinyl-source-stream": "^2.0.0" }, "engines": { diff --git a/tasks/browser-sync-server.js b/tasks/browser-sync-server.js index e99afcc..717f7d8 100644 --- a/tasks/browser-sync-server.js +++ b/tasks/browser-sync-server.js @@ -3,8 +3,7 @@ */ 'use strict'; -const gulp = require('gulp'), - fs = require('fs'); +const fs = require('fs'); module.exports = function(options) { @@ -15,7 +14,7 @@ module.exports = function(options) { options.browserSync.init({ notify: false, server: { - baseDir: "./", + baseDir: './', directory: listDirectory }, snippetOptions: { diff --git a/tasks/build-custom-js.js b/tasks/build-custom-js.js index 9310220..4740e7a 100644 --- a/tasks/build-custom-js.js +++ b/tasks/build-custom-js.js @@ -5,7 +5,6 @@ const gulp = require('gulp'), browserify = require('browserify'), - babelify = require('babelify'), source = require('vinyl-source-stream'); module.exports = function(options) { @@ -16,8 +15,19 @@ module.exports = function(options) { // Remove sourcemap for production debug: !options.isProduction }) + // If you need to 'babelify' with options: + // .transform('babelify', { + // presets: [ + // ['@babel/preset-env', { + // exclude: [ + // 'transform-template-literals', + // ], + // debug: true, + // }], + // ], + // }) .transform('babelify', { - presets: ['es2015'] + presets: ['@babel/preset-env'], }) .bundle().on('error', function(err) { options.showError.apply(this, ['JS error', err]) From 1911df767af09808586be6d0d9606f20f23cbb22 Mon Sep 17 00:00:00 2001 From: Vladimir Pikul Date: Fri, 23 Aug 2019 17:01:45 +0300 Subject: [PATCH 2/2] eslint-config-airbnb-base updated to 14 version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index dcd889f..476802f 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,7 @@ "browser-sync": "^2.18.0", "browserify": "^16.5.0", "del": "^3.0.0", - "eslint-config-airbnb-base": "^13.1.0", + "eslint-config-airbnb-base": "^14.0.0", "eslint-plugin-import": "^2.14.0", "files-exist": "^1.1.0", "gulp": "^4.0.0",