Skip to content

Commit 234de2b

Browse files
filipesilvahansl
authored andcommitted
fix(build): fix broken sourcemaps (#839)
1 parent 9b8334f commit 234de2b

File tree

4 files changed

+7
-11
lines changed

4 files changed

+7
-11
lines changed

addon/ng2/blueprints/ng2/files/__path__/tsconfig.json

-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
"declaration": false,
55
"emitDecoratorMetadata": true,
66
"experimentalDecorators": true,
7-
"mapRoot": "",
87
"module": "commonjs",
98
"moduleResolution": "node",
109
"noEmitOnError": true,

addon/ng2/blueprints/ng2/files/angular-cli-build.js

+4-4
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@ module.exports = function(defaults) {
77
vendorNpmFiles: [
88
'systemjs/dist/system-polyfills.js',
99
'systemjs/dist/system.src.js',
10-
'zone.js/dist/*.js',
10+
'zone.js/dist/**/*.+(js|js.map)',
1111
'es6-shim/es6-shim.js',
12-
'reflect-metadata/*.js',
13-
'rxjs/**/*.js',
14-
'@angular/**/*.js'
12+
'reflect-metadata/**/*.+(js|js.map)',
13+
'rxjs/**/*.+(js|js.map)',
14+
'@angular/**/*.+(js|js.map)'
1515
]
1616
});
1717
};

lib/broccoli/angular2-app.js

+2-5
Original file line numberDiff line numberDiff line change
@@ -404,21 +404,18 @@ class Angular2App extends BroccoliPlugin {
404404
}
405405

406406
_getBundleTree(preBundleTree){
407-
var indexFile = path.join(this._sourceDir, 'index.html');
408-
var indexContent = fs.readFileSync(indexFile, 'utf8');
409-
var scriptTagVendorFiles = indexContent.match(/vendor\/[^"']*\.js/gi);
410407
var vendorTree = this._getVendorNpmTree();
411408
var assetsTree = this._getAssetsTree();
412409

413410
var scriptTree = new BroccoliFunnel(preBundleTree, {
414-
include: scriptTagVendorFiles
411+
include: this._options.polyfills
415412
});
416413

417414
var nonJsTree = new BroccoliFunnel(preBundleTree, {
418415
exclude: ['**/*.js', '**/*.js.map']
419416
});
420417
var jsTree = new BroccoliFunnel(preBundleTree, {
421-
include: ['**/*.js']
418+
include: ['**/*.js', '**/*.js.map']
422419
});
423420

424421
var bundleTree = new BundlePlugin([jsTree]);

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
"shelljs": "^0.7.0",
5353
"silent-error": "^1.0.0",
5454
"symlink-or-copy": "^1.0.3",
55-
"systemjs-builder": "^0.15.16",
55+
"systemjs-builder": "0.15.17",
5656
"typescript": "^1.8.10",
5757
"typings": "^0.8.1"
5858
},

0 commit comments

Comments
 (0)