生成错误:存在两种使用此名称的不同类型,但是它们不相关

Dan*_*cro 5 rxjs yarnpkg angular

构建我的JHipster Angular项目时出现此错误

[ERROR] Error at /Users/Dan/work/gba/node_modules/ng-jhipster/src/interceptor/interceptable-http.d.ts:4:22: Class 'InterceptableHttp' incorrectly extends base class 'Http'.
[ERROR]   Types of property 'request' are incompatible.
[ERROR]     Type '(url: string | Request, options?: RequestOptionsArgs) => Observable<Response>' is not assignable to type '(url: string | Request, options?: RequestOptionsArgs) => Observable<Response>'. Two different types with this name exist, but they are unrelated.
[ERROR]       Type 'Observable<Response>' is not assignable to type 'Observable<Response>'. Two different types with this name exist, but they are unrelated.
[ERROR]         Property 'source' is protected but type 'Observable<T>' is not a class derived from 'Observable<T>'.
Run Code Online (Sandbox Code Playgroud)

我在这个项目中遇到这个问题。

完整的Travis构建错误在这里

Dan*_*cro 3

这让我呆了几天。为了修复它,我删除了我的/target目录和yarn.lock文件。