我是knockout.js的新手,是否可以在knockout.js中触发点击事件?
最佳答案
有一些内置的绑定(bind)可以实现类似的功能,但是您可以使用事件绑定(bind) Hook 到任何事件。
The event binding allows you to add an event handler for a specified event so that your chosen JavaScript function will be invoked when that event is triggered for the associated DOM element. This can be used to bind to any event, such as keypress, mouseover or mouseout.
关于javascript - 如何像jquery中的触发器('click'一样触发knockout.js中的点击事件?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23404092/