ng2:在 keyup 上更新 FirebaseListObservable 中的值

ng2: Update value in FirebaseListObservable on keyup

我正在使用 Angular2 和 Firebase 作为后端。我的目标:拥有一些应该跨设备同步的输入字段 --> 3 向数据绑定。

我的方法:FirebaseListObservablengFor 在模板中进行。

现在,问题是每次我按下一个键时,整个 array/all 输入字段都会重新呈现(尽管是那个词!:D),而不仅仅是我当前输入的那个.这使得光标从输入中弹出,所以我必须再次聚焦它并且重新开始奇怪的行为。

我在使用 Firebase 时是否遗漏了一些非常普遍的东西? As the docs state 在 "Change Propagation" 中,只有更新的元素会被重新渲染(显然不是这种情况)。

使用*ngFor="let input of item;trackBy:input?.id"

https://angular.io/docs/ts/latest/api/common/index/NgFor-directive.html