...
option:{
array: new can.List([1, 2, 3, 4, 5])
}
...
{{#each option.array}}
<div>
<label for="d{{@index}}"></label>
<input id="d{{@index}}" can-value="option.array[{{@index}}]"/>
</div>
{{/each}}
Above code generates 5 text boxes with correct id. But it does not create observables.
What is the correct format that I should provide to can-value attribute to make it an observable?
Aucun commentaire:
Enregistrer un commentaire