Replace all elements in Knockout.js observableArray

允我心安 提交于 2019-12-03 09:19:11
RP Niemeyer

The technique that you are using is the recommended approach for completely replacing the data in an observableArray. An observableArray is actually just a normal observable with extra functions added for useful array operations that act on the underlying array and trigger notifications.

user887

I found that the recommended approach does not work in IE9 or lower. Instead I had recreate the object,

vm.roles = ko.observableArray(["1","2"])
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!