@@ -160,7 +160,7 @@ class Angular2App extends BroccoliPlugin {
160
160
}
161
161
162
162
if ( this . ngConfig . apps [ 0 ] . mobile ) {
163
- var ServiceWorkerPlugin = require ( 'angular2- service-worker' ) . ServiceWorkerPlugin ;
163
+ var ServiceWorkerPlugin = require ( '@angular/ service-worker' ) . ServiceWorkerPlugin ;
164
164
var swTree = new ServiceWorkerPlugin ( merged ) ;
165
165
merged = BroccoliMergeTrees ( [ merged , swTree ] , {
166
166
overwrite : true
@@ -357,7 +357,7 @@ class Angular2App extends BroccoliPlugin {
357
357
] ;
358
358
359
359
if ( this . ngConfig . apps [ 0 ] . mobile ) {
360
- vendorNpmFiles . push ( 'angular2- service-worker/dist/worker.js' )
360
+ vendorNpmFiles . push ( '@angular/ service-worker/dist/worker.js' )
361
361
}
362
362
363
363
if ( this . _options . vendorNpmFiles ) {
@@ -415,6 +415,7 @@ class Angular2App extends BroccoliPlugin {
415
415
var indexFile = path . join ( this . _sourceDir , 'index.html' ) ;
416
416
var indexContent = fs . readFileSync ( indexFile , 'utf8' ) ;
417
417
var scriptTagVendorFiles = indexContent . match ( / v e n d o r \/ [ ^ " ' ] * \. j s / gi) ;
418
+ var vendorTree = this . _getVendorNpmTree ( ) ;
418
419
419
420
var scriptTree = new BroccoliFunnel ( preBundleTree , {
420
421
include : scriptTagVendorFiles
@@ -430,7 +431,7 @@ class Angular2App extends BroccoliPlugin {
430
431
var bundleTree = new BundlePlugin ( [ jsTree ] ) ;
431
432
432
433
if ( this . ngConfig . apps [ 0 ] . mobile ) {
433
- bundleTree = concat ( BroccoliMergeTrees ( [ jsTree , scriptTree , bundleTree ] , {
434
+ bundleTree = concat ( BroccoliMergeTrees ( [ vendorTree , jsTree , scriptTree , bundleTree ] , {
434
435
overwrite : true
435
436
} ) , {
436
437
headerFiles : this . _options . polyfills . concat ( [
0 commit comments