rxjs/Subscription has no exported member 'Subscription'
There is a lot of breaking changes with RxJS 6. For example, prototype methods as
myObservable.map(data => data * 2)
won't work anymore and must be replaced by
myObservable.pipe(map(data => data * 2))
All details can be found here: https://github.com/ReactiveX/rxjs/blob/master/docs_app/content/guide/v6/migration.md
Until you have fixed all breaking changes, you can make your old code work again with rxjs-compat
(https://github.com/ReactiveX/rxjs/tree/master/compat).
This package is required to get backwards compatibility with RxJS previous to version 6. It contains the imports to add operators to
Observable.prototype
and creation methods toObservable
.
Type this to install it:
npm install -s rxjs-compat
I hope your problem will resolve using this below statement
import Subscription from 'rxjs'
You can fix it with this:
import {from} from 'rxjs';
And, instead of: return Observable.fromPromise(new Promise((resolve, reject) => {
Now just do:
return from(new Promise((resolve, reject) => {
The same applies to Observable.of