Skip to content

Commit 3531838

Browse files
authored
Merge pull request #4709 from NativeScript/fatme/ensure-dependencies-are-installed
fix: ensure dependencies are installed before spawning webpack
2 parents 538179b + 4cbd349 commit 3531838

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lib/services/webpack/webpack-compiler-service.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ export class WebpackCompilerService extends EventEmitter implements IWebpackComp
1111
constructor(
1212
private $childProcess: IChildProcess,
1313
public $hooksService: IHooksService,
14-
private $logger: ILogger
14+
private $logger: ILogger,
15+
private $pluginsService: IPluginsService
1516
) { super(); }
1617

1718
public async compileWithWatch(platformData: IPlatformData, projectData: IProjectData, prepareData: IPrepareData): Promise<any> {
@@ -102,6 +103,8 @@ export class WebpackCompilerService extends EventEmitter implements IWebpackComp
102103
const envData = this.buildEnvData(platformData.platformNameLowerCase, projectData, prepareData);
103104
const envParams = this.buildEnvCommandLineParams(envData, platformData);
104105

106+
await this.$pluginsService.ensureAllDependenciesAreInstalled(projectData);
107+
105108
const args = [
106109
path.join(projectData.projectDir, "node_modules", "webpack", "bin", "webpack.js"),
107110
"--preserve-symlinks",

0 commit comments

Comments
 (0)