success callback after knockout.js finishes rendering all the elements

后端 未结 8 1175
你的背包
你的背包 2020-12-01 04:39

I have implemented a knockout foreach binding, with multiple templates in the same page, one of the example is given here, what I am interested is in finding out when a bloc

8条回答
  •  庸人自扰
    2020-12-01 04:56

    In version 3.5 Knockout provides events to notify when the contents of a node have been bound

    HTML

    ...

    JavaScript

    function bindingComplete(){
    ...
    }
    

    If you an create event binding expression at a point in the DOM that encapsulates all your child data binding expression, then it's tantamount to a page binding complete event

    reference https://knockoutjs.com/documentation/binding-lifecycle-events.html

提交回复
热议问题