View | Details | Raw Unified | Return to bug 15522
Collapse All | Expand All

(-)a/gulpfile.js (-8 / +13 lines)
Lines 36-58 gulp.task( "watch", () => { Link Here
36
36
37
let vendorBuilt = false;
37
let vendorBuilt = false;
38
38
39
gulp.task( "build", () => {
39
function getBundler() {
40
    let bundler = browserify( {
40
    let bundler = browserify( {
41
        debug: true
41
        debug: !process.env.PRODUCTION,
42
    } )
42
    } );
43
        .transform( "babelify", { presets: [ "es2015", "react" ], plugins: [ "transform-class-properties" ] } );
43
44
    if ( process.env.DESCRIPTION ) {
45
        bundler.transform( "uglifyify" );
46
    }
44
47
48
    return bundler;
49
}
50
51
gulp.task( "build", () => {
45
    if ( !vendorBuilt ) {
52
    if ( !vendorBuilt ) {
46
        browserify( {
53
        getBundler().require( VENDOR_DEPENDENCIES )
47
            require: VENDOR_DEPENDENCIES,
48
            debug: true,
49
        } )
50
            .bundle()
54
            .bundle()
51
            .on( "error", gutil.log )
55
            .on( "error", gutil.log )
52
            .pipe( source( "vendor.js" ) )
56
            .pipe( source( "vendor.js" ) )
53
            .pipe( gulp.dest( BASE + "/built/" ) );
57
            .pipe( gulp.dest( BASE + "/built/" ) );
54
    }
58
    }
55
59
60
    let bundler = getBundler().transform( "babelify", { presets: [ "es2015", "react" ], plugins: [ "transform-class-properties" ] } );
56
61
57
    return gulp.src( BUILT_FILES )
62
    return gulp.src( BUILT_FILES )
58
        .pipe( tap( file => {
63
        .pipe( tap( file => {
(-)a/package.json (+1 lines)
Lines 18-23 Link Here
18
    "promise-polyfill": "^6.0.2",
18
    "promise-polyfill": "^6.0.2",
19
    "react": "^16.0.0",
19
    "react": "^16.0.0",
20
    "react-dom": "^16.0.0",
20
    "react-dom": "^16.0.0",
21
    "uglifyify": "^4.0.4",
21
    "vinyl-source-stream": "^1.1.0",
22
    "vinyl-source-stream": "^1.1.0",
22
    "whatwg-fetch": "^2.0.3"
23
    "whatwg-fetch": "^2.0.3"
23
  },
24
  },
(-)a/yarn.lock (-3 / +31 lines)
Lines 788-793 combine-source-map@~0.7.1: Link Here
788
    lodash.memoize "~3.0.3"
788
    lodash.memoize "~3.0.3"
789
    source-map "~0.5.3"
789
    source-map "~0.5.3"
790
790
791
commander@~2.11.0:
792
  version "2.11.0"
793
  resolved "https://registry.yarnpkg.com/commander/-/commander-2.11.0.tgz#157152fd1e7a6c8d98a5b715cf376df928004563"
794
791
concat-map@0.0.1:
795
concat-map@0.0.1:
792
  version "0.0.1"
796
  version "0.0.1"
793
  resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b"
797
  resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b"
Lines 1025-1030 expand-tilde@^2.0.2: Link Here
1025
  dependencies:
1029
  dependencies:
1026
    homedir-polyfill "^1.0.1"
1030
    homedir-polyfill "^1.0.1"
1027
1031
1032
extend@^1.2.1:
1033
  version "1.3.0"
1034
  resolved "https://registry.yarnpkg.com/extend/-/extend-1.3.0.tgz#d1516fb0ff5624d2ebf9123ea1dac5a1994004f8"
1035
1028
extend@^3.0.0:
1036
extend@^3.0.0:
1029
  version "3.0.1"
1037
  version "3.0.1"
1030
  resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444"
1038
  resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444"
Lines 1768-1774 minimatch@^2.0.1: Link Here
1768
  dependencies:
1776
  dependencies:
1769
    brace-expansion "^1.0.0"
1777
    brace-expansion "^1.0.0"
1770
1778
1771
minimatch@^3.0.4:
1779
minimatch@^3.0.2, minimatch@^3.0.4:
1772
  version "3.0.4"
1780
  version "3.0.4"
1773
  resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083"
1781
  resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083"
1774
  dependencies:
1782
  dependencies:
Lines 2280-2285 source-map@^0.5.6, source-map@~0.5.3: Link Here
2280
  version "0.5.6"
2288
  version "0.5.6"
2281
  resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.6.tgz#75ce38f52bf0733c5a7f0c118d81334a2bb5f412"
2289
  resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.6.tgz#75ce38f52bf0733c5a7f0c118d81334a2bb5f412"
2282
2290
2291
source-map@~0.5.1:
2292
  version "0.5.7"
2293
  resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc"
2294
2283
sparkles@^1.0.0:
2295
sparkles@^1.0.0:
2284
  version "1.0.0"
2296
  version "1.0.0"
2285
  resolved "https://registry.yarnpkg.com/sparkles/-/sparkles-1.0.0.tgz#1acbbfb592436d10bbe8f785b7cc6f82815012c3"
2297
  resolved "https://registry.yarnpkg.com/sparkles/-/sparkles-1.0.0.tgz#1acbbfb592436d10bbe8f785b7cc6f82815012c3"
Lines 2372-2378 through2@^2.0.0, through2@^2.0.3: Link Here
2372
    readable-stream "^2.1.5"
2384
    readable-stream "^2.1.5"
2373
    xtend "~4.0.1"
2385
    xtend "~4.0.1"
2374
2386
2375
"through@>=2.2.7 <3":
2387
"through@>=2.2.7 <3", through@~2.3.4:
2376
  version "2.3.8"
2388
  version "2.3.8"
2377
  resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5"
2389
  resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5"
2378
2390
Lines 2416-2421 ua-parser-js@^0.7.9: Link Here
2416
  version "0.7.14"
2428
  version "0.7.14"
2417
  resolved "https://registry.yarnpkg.com/ua-parser-js/-/ua-parser-js-0.7.14.tgz#110d53fa4c3f326c121292bbeac904d2e03387ca"
2429
  resolved "https://registry.yarnpkg.com/ua-parser-js/-/ua-parser-js-0.7.14.tgz#110d53fa4c3f326c121292bbeac904d2e03387ca"
2418
2430
2431
uglify-es@^3.0.15:
2432
  version "3.1.3"
2433
  resolved "https://registry.yarnpkg.com/uglify-es/-/uglify-es-3.1.3.tgz#a21eeb149cb120a1f8302563689e19496550780b"
2434
  dependencies:
2435
    commander "~2.11.0"
2436
    source-map "~0.5.1"
2437
2438
uglifyify@^4.0.4:
2439
  version "4.0.4"
2440
  resolved "https://registry.yarnpkg.com/uglifyify/-/uglifyify-4.0.4.tgz#929f47acdbbf5e0626eae5002acc1e32349c7b3c"
2441
  dependencies:
2442
    convert-source-map "~1.1.0"
2443
    extend "^1.2.1"
2444
    minimatch "^3.0.2"
2445
    through "~2.3.4"
2446
    uglify-es "^3.0.15"
2447
2419
umd@^3.0.0:
2448
umd@^3.0.0:
2420
  version "3.0.1"
2449
  version "3.0.1"
2421
  resolved "https://registry.yarnpkg.com/umd/-/umd-3.0.1.tgz#8ae556e11011f63c2596708a8837259f01b3d60e"
2450
  resolved "https://registry.yarnpkg.com/umd/-/umd-3.0.1.tgz#8ae556e11011f63c2596708a8837259f01b3d60e"
2422
- 

Return to bug 15522