Skip to content

Different versions of RxJS not supported #14579

@ahasall

Description

@ahasall

🐞 Bug report

Command (mark with an x)

- [ ] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc

Is this a regression?

No

Description

The Angular CLI ecosystem supports only one version of RxJS which is 6.4.0.
I expect different versions of RxJS to be supported because Angular itself supports a broader range of RxJS versions (^6.4.0)

🔬 Minimal Reproduction

https://github.com/ahasall/rxjs-v6.4-v6.5-bug

yarn install
yarn build

🔥 Exception or Error

If you use RxJS v6.5.2 and a library that depends on RxJS v6.4.0, you may get a TS2322 error.

For example, when working with the new Architect API, I encounter the following error:
Type 'Observable' is not assignable to type 'BuilderOutputLike' while

export declare type BuilderOutputLike = Observable<BuilderOutput> | Promise<BuilderOutput> | BuilderOutput;

🌍 Your Environment


@angular-devkit/architect          0.800.0
@angular-devkit/build-angular      0.800.0
@angular-devkit/build-ng-packagr   0.800.0
@angular-devkit/build-optimizer    0.800.0
@angular-devkit/build-webpack      0.800.0
@angular-devkit/core               8.0.0
@angular-devkit/schematics         8.0.0
@ngtools/json-schema               1.1.0
@ngtools/webpack                   8.0.0
@schematics/angular                8.0.0
@schematics/update                 0.800.0
ng-packagr                         5.2.0
rxjs                               6.5.2
typescript                         3.5.1
webpack                            4.30.0

Anything else relevant?
A workaround for people encountering this issue is to downgrade their version of RxJS to 6.4.0

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions