javascript - KnockoutJS foreach sometimes not displaying results -
i don't have code sample reproduce (situation complex), scenario have this:
i have knockoutjs (version 3.1.0) "foreach" binding against computed() property. computed property returns data based on value of observable property, plus few filters based on observables (i.e. return bookmarks in selected category, plus filter search terms).
my problem "sometimes" (and randomly) no results displayed category know has results. select category , [usually] results displayed, when re-select category did not show, results appear.
a comment question (knockout js data binding not updated) allowed me discover answer.
i watched javascript console in browser , discovered getting error: "unable property 'tolowercase' of undefined or null reference"
by fixing (by first checking value - incidentally, ko observable - being converted lower has value) , stopping error, view consistently displays data now.
the console friend!
Comments
Post a Comment