File tree 2 files changed +11
-0
lines changed
2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change 62
62
"mocha" : " 6.1.4" ,
63
63
"nativescript-dev-typescript" : " next" ,
64
64
"nativescript-dev-webpack" : " webpack" ,
65
+ "remove-strict-webpack-plugin" : " ~0.1.2" ,
65
66
"sinon" : " ^7.3.2" ,
66
67
"tslint" : " ^4.5.1" ,
67
68
"typescript" : " ~3.4.5"
Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ const { BundleAnalyzerPlugin } = require("webpack-bundle-analyzer");
13
13
const { NativeScriptWorkerPlugin } = require ( "nativescript-worker-loader/NativeScriptWorkerPlugin" ) ;
14
14
const TerserPlugin = require ( "terser-webpack-plugin" ) ;
15
15
const { getAngularCompilerPlugin } = require ( "nativescript-dev-webpack/plugins/NativeScriptAngularCompilerPlugin" ) ;
16
+ const RemoveStrictPlugin = require ( 'remove-strict-webpack-plugin' ) ;
16
17
const hashSalt = Date . now ( ) . toString ( ) ;
17
18
18
19
module . exports = env => {
@@ -34,6 +35,9 @@ module.exports = env => {
34
35
const dist = resolve ( projectRoot , nsWebpack . getAppPath ( platform , projectRoot ) ) ;
35
36
const appResourcesPlatformDir = platform === "android" ? "Android" : "iOS" ;
36
37
38
+ // Workaround for CLI issue in version `6.0.0-2019-06-19-13454`
39
+ env . unitTesting = true ;
40
+
37
41
const {
38
42
// The 'appPath' and 'appResourcesPath' values are fetched from
39
43
// the nsconfig.json configuration file
@@ -314,5 +318,11 @@ module.exports = env => {
314
318
config . plugins . push ( new webpack . HotModuleReplacementPlugin ( ) ) ;
315
319
}
316
320
321
+ // Workaround for issue caused by
322
+ // `https://github.com/NativeScript/nativescript-angular/blob/f506b3cb047180c7e208b49ab2def690fad6691e/nativescript-angular/http-client/http-client.module.ts#L5-L7
323
+ if ( unitTesting ) {
324
+ config . plugins . push ( new RemoveStrictPlugin ( ) ) ;
325
+ }
326
+
317
327
return config ;
318
328
} ;
You can’t perform that action at this time.
0 commit comments