Rxjs 角度6:未定义运算符.share

Rxjs 角度6:未定义运算符.share,rxjs,angular6,Rxjs,Angular6,我将nativescript项目升级为Angular 6,但现在运行它时,立即出现以下错误: JS: bootstrap: ERROR BOOTSTRAPPING ANGULAR JS: bootstrap: operators.share is not a function JS: JS: TypeError: operators.share is not a function JS: at new ApplicationRef (file:///data/data/io.neocle

我将nativescript项目升级为Angular 6,但现在运行它时,立即出现以下错误:

JS: bootstrap: ERROR BOOTSTRAPPING ANGULAR
JS: bootstrap: operators.share is not a function
JS:
JS: TypeError: operators.share is not a function
JS:     at new ApplicationRef (file:///data/data/io.neocles.dev/files/app/tns_modules/@angular/core/bundles/core.umd.js:4446:67)
JS:     at _createClass (file:///data/data/io.neocles.dev/files/app/tns_modules/@angular/core/bundles/core.umd.js:8210:20)
JS:     at _createProviderInstance$1 (file:///data/data/io.neocles.dev/files/app/tns_modules/@angular/core/bundles/core.umd.js:8172:26)
JS:     at initNgModule (file:///data/data/io.neocles.dev/files/app/tns_modules/@angular/core/bundles/core.umd.js:8108:32)
JS:     at new NgModuleRef_ (file:///data/data/io.neocles.dev/files/app/tns_modules/@angular/core/bundles/core.umd.js:8831:9)
JS:     at createNgModuleRef (file:///data/data/io.neocles.dev/files/app/tns_modules/@angular/core/bundles/core.umd.js:8820:12)
JS:     at Object.debugCreateNgModuleRef [as createNgModuleRef] (file:///data/data/io.neocles.dev/files/app/tns_modules/@angular/core/bundles/core.umd.js:10645:12)
JS:     at NgModuleFactory_.create (...
我升级到rxjs 6,但仍然使用rxjs compat。我在根目录中包含一个名为“rxjs操作符”的文件,该文件导入我使用的所有rxjs组件。共享不是其中之一,但将其添加到列表中不会改变任何事情

我将错误追溯到core.umd.js中的以下位置:

    this.isStable =
        rxjs.merge(isCurrentlyStable, isStable.pipe(operators.share()));

为什么会出现此错误以及如何修复此错误?

在将NativeScript升级到Angular 6后,出现了相同的错误。
在我的例子中,我运行了错误的NativeScript版本-->使用
NativeScript>4.1
和最新的
NativeScript angular
版本。

什么是
rxjs操作符
?这不是
rxjs
的一部分,也不是
rxjs compat
@martin,它是我自己创建的一个文件,包含像
import'rxjs/add/observate/forkJoin'这样的行对于我在整个应用程序中使用的每个方法,您是否解决了此问题?我也有同样的问题。@JeffB我最终摆脱了rxjs compat,只是将整个代码库升级到了rxjs6。似乎有办法