Angular - “has no exported member 'Observable'”

后端 未结 14 1913
陌清茗
陌清茗 2020-12-12 11:16

Typescript code:

import { Injectable } from \'@angular/core\';
import { Observable } from \'rxjs/Observable\';
import { of         


        
14条回答
  •  醉酒成梦
    2020-12-12 11:41

    Update angular-in-memory-web-api version. The default angular-in-memory-web-api version installed during the tutorial angular-tour-of-heroes was 0.4. It worked like a charm in my case. (Using Angular 7 with RxJS 6)

    npm i angular-in-memory-web-api@0.8.0
    

提交回复
热议问题