I'd like to join $index
and $data
in text binding:
<ul data-bind='foreach: myItems'>
<li data-bind="text: $index() + ': ' + $data()"></li>
</ul>
but the syntax above is not working. Is such scenario not supported in KO? Have I to write some helper function or computed observable into my model?