Skip to content
This repository was archived by the owner on Aug 7, 2021. It is now read-only.

Commit 48da2a1

Browse files
authored
Merge pull request #976 from NativeScript/tachev/source-map-files
fix: do not require `.js.map` files in the entry points when `devtool: "source-map"` is used
2 parents d2bf15b + 24aff45 commit 48da2a1

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "nativescript-dev-webpack",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"main": "index",
55
"description": "",
66
"homepage": "http://www.telerik.com",

plugins/GenerateNativeScriptEntryPointsPlugin.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ exports.GenerateNativeScriptEntryPointsPlugin = (function () {
5555
entryChunk = chunk;
5656
} else {
5757
chunk.files.forEach(fileName => {
58-
if (!this.isHMRFile(fileName)) {
58+
if (!this.isHMRFile(fileName) && this.isSourceFile(fileName)) {
5959
requiredFiles.push(fileName);
6060
}
6161
});
@@ -96,5 +96,9 @@ exports.GenerateNativeScriptEntryPointsPlugin = (function () {
9696
return fileName.indexOf("hot-update") > -1;
9797
}
9898

99+
GenerateNativeScriptEntryPointsPlugin.prototype.isSourceFile = function (fileName) {
100+
return fileName.endsWith(".js");
101+
}
102+
99103
return GenerateNativeScriptEntryPointsPlugin;
100104
})();

0 commit comments

Comments
 (0)