only browserify-shim the dist files (#675)
Showing
3 changed files
with
5 additions
and
7 deletions
... | @@ -16,7 +16,7 @@ | ... | @@ -16,7 +16,7 @@ |
16 | "build:js": "npm-run-all build:js:babel build:js:browserify build:js:bannerize build:js:uglify", | 16 | "build:js": "npm-run-all build:js:babel build:js:browserify build:js:bannerize build:js:uglify", |
17 | "build:js:babel": "babel src -d es5", | 17 | "build:js:babel": "babel src -d es5", |
18 | "build:js:bannerize": "bannerize dist/videojs-contrib-hls.js --banner=scripts/banner.ejs", | 18 | "build:js:bannerize": "bannerize dist/videojs-contrib-hls.js --banner=scripts/banner.ejs", |
19 | "build:js:browserify": "browserify . -s videojs-contrib-hls -o dist/videojs-contrib-hls.js", | 19 | "build:js:browserify": "browserify . -s videojs-contrib-hls -t browserify-shim -o dist/videojs-contrib-hls.js", |
20 | "build:js:uglify": "uglifyjs dist/videojs-contrib-hls.js --comments --mangle --compress -o dist/videojs-contrib-hls.min.js", | 20 | "build:js:uglify": "uglifyjs dist/videojs-contrib-hls.js --comments --mangle --compress -o dist/videojs-contrib-hls.min.js", |
21 | "build:test": "npm-run-all build:test:manifest build:test:js", | 21 | "build:test": "npm-run-all build:test:manifest build:test:js", |
22 | "build:test:js": "node scripts/build-test.js", | 22 | "build:test:js": "node scripts/build-test.js", |
... | @@ -52,11 +52,6 @@ | ... | @@ -52,11 +52,6 @@ |
52 | ], | 52 | ], |
53 | "author": "Brightcove, Inc", | 53 | "author": "Brightcove, Inc", |
54 | "license": "Apache-2.0", | 54 | "license": "Apache-2.0", |
55 | "browserify": { | ||
56 | "transform": [ | ||
57 | "browserify-shim" | ||
58 | ] | ||
59 | }, | ||
60 | "browserify-shim": { | 55 | "browserify-shim": { |
61 | "qunit": "global:QUnit", | 56 | "qunit": "global:QUnit", |
62 | "sinon": "global:sinon", | 57 | "sinon": "global:sinon", | ... | ... |
... | @@ -5,6 +5,7 @@ var glob = require('glob'); | ... | @@ -5,6 +5,7 @@ var glob = require('glob'); |
5 | glob('test/**/*.test.js', function(err, files) { | 5 | glob('test/**/*.test.js', function(err, files) { |
6 | browserify(files) | 6 | browserify(files) |
7 | .transform('babelify') | 7 | .transform('babelify') |
8 | .transform('browserify-shim') | ||
8 | .bundle() | 9 | .bundle() |
9 | .pipe(fs.createWriteStream('dist-test/videojs-contrib-hls.js')); | 10 | .pipe(fs.createWriteStream('dist-test/videojs-contrib-hls.js')); |
10 | }); | 11 | }); | ... | ... |
... | @@ -8,7 +8,9 @@ glob('test/**/*.test.js', function(err, files) { | ... | @@ -8,7 +8,9 @@ glob('test/**/*.test.js', function(err, files) { |
8 | cache: {}, | 8 | cache: {}, |
9 | packageCache: {}, | 9 | packageCache: {}, |
10 | plugin: [watchify] | 10 | plugin: [watchify] |
11 | }).transform('babelify'); | 11 | }) |
12 | .transform('babelify') | ||
13 | .transform('browserify-shim'); | ||
12 | 14 | ||
13 | var bundle = function() { | 15 | var bundle = function() { |
14 | b.bundle().pipe(fs.createWriteStream('dist-test/videojs-contrib-hls.js')); | 16 | b.bundle().pipe(fs.createWriteStream('dist-test/videojs-contrib-hls.js')); | ... | ... |
-
Please register or sign in to post a comment