0

I'm trying to publish a dotnet core 2.2 app with angular.

During the publishing I get following error:

Version of @angular/compiler-cli needs to be 2.3.1 or greater. Current version is "7.2.15"

I've tried to fix the version, running npm install and npm update. But honestly speaking I don't understand what is the problem.

I've tried to publish with following command:

dotnet publish -c Release -r linux-x64

Publish works without error.

RBull
  • 41
  • 1
  • 4

2 Answers2

0

Try to update webpack. It solves this issue

npm install --save-dev @ngtools/webpack@latest

I had similer issue with .net core. This link helped me

Update to angular 5 throws Version of @angular/compiler-cli needs to be 2.3.1 or greater. Current version is 5.1.0

Asif Rahman
  • 453
  • 7
  • 16
  • Can you please elaborate more on why this solve the issue? How have you obtained such information? Is there an official discussion which explains it? – bracco23 Jun 07 '19 at 09:22
0

I've tried to follow your suggestion, but with this fix I got following error "Cannot find module '@angular/compiler-cli/ngcc'". Trying to fix that leads to more and more needed peer dependencies to install by myself.

RBull
  • 41
  • 1
  • 4