Observable.of is not a function

后端 未结 19 760
旧时难觅i
旧时难觅i 2020-11-30 19:41

I am having issue with importing Observable.of function in my project. My Intellij sees everything. In my code I have:

import {Observable} from          


        
19条回答
  •  余生分开走
    2020-11-30 20:22

    Patching wasn't working for me, for whatever reason, so I had to resort to this method:

    import { of } from 'rxjs/observable/of'
    
    // ...
    
    return of(res)
    

提交回复
热议问题