Closed jortiz-belike closed 2 years ago
Are you using npm 7 by chance? There seem to be issues with Angular 11.2.6, updating and npm 7 in general: https://github.com/angular/angular-cli/issues/20375
When migrating from angular 10 to 11, angular removes tsconfig.base.json
the following works:
npm i -g @angular/cli@11
ng new ng11-gql
cd ng11-gql && ng add apollo angular
npm start
runs fineAngular CLI: 11.2.15
Node: 14.17.0
OS: darwin x64
Angular: 11.2.14
... animations, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, router
Ivy Workspace: Yes
Package Version
---------------------------------------------------------
@angular-devkit/architect 0.1102.15
@angular-devkit/build-angular 0.1102.15
@angular-devkit/core 11.2.15
@angular-devkit/schematics 11.2.15
@angular/cli 11.2.15
@schematics/angular 11.2.15
@schematics/update 0.1102.15
rxjs 6.6.7
typescript 4.1.6
Describe the bug
I have a version of Angular 11.2.6, after migrating from version 8 in which the project was created. When running the command
ng add angular-apollo
I get the error that I mention, I have read that version 2.0.4 solves the error, but the one that is trying to install is that same The strangest thing of all is that if I create a project of 0 in version 11.2.6, the command does work, it could not understand what changes in the project in the increase of versions.To Reproduce Try to install apollo-angular
Expected behavior
I want the library to be able to be installed as in a new angular project (it does not have tsconfig.base and the error does not appear)
Environment:
@apollo/client
: Does not installapollo-angular
: ^2.4.0graphql
: Does not install@angular/core
: ~11.2.6@angular/cli
: 11.2.5typescript
: 4.0.7