我收到了tslint警告select is deprecated: from 6.1.0. Use the pipeable
'select' operator instead.
我的选择器如下所示
private availableStudents$ = this.store.select(getAvailableStudents);
也是我的package.json
"rxjs": "^6.0.0"
"tslint": "~5.9.1"
"typescript": "^2.9.2"
"@angular/cli": "~6.1.2
答案 0 :(得分:5)
尝试以下操作:
private availableStudents$ = this.store.pipe(select(getAvailableStudents));
上面使用警告中建议的可管道运算符。
并确保将其导入:
import { Store, select } from '@ngrx/store';