问题描述
我创建了一个简单的 reducer 作为 ngRx 的一部分,on()
方法出现以下错误。
此外,reducer_creator.d.ts 文件中出现了一些错误:
此外,这是我的 package.json ngrx 和 typescript 版本:
"@ngrx/effects": "^11.0.1","@ngrx/store": "^11.0.1","@ngrx/store-devtools": "^11.0.1","typescript": "~3.1.6"
有什么建议可以解决这个问题?
解决方法
NgRx v11 需要使用 TypeScript 4。 https://ngrx.io/guide/migration/v11