Hi!
I’m getting some data via fetch()
and updating an array initialized as an Observable
. This works just fine, but when trying to run the value through an Each
nothing happens. I’ve made a mockup of what I’m trying to do.
<JavaScript>
var Observable = require("FuseJS/Observable");
var arr = [{
text: "Heisan"
},
{
text: "Hade"
}];
var fArr = Observable();
fArr.value = arr;
module.exports = {
arr: fArr
}
</JavaScript>
<StackPanel>
<Each Items="{arr}">
<Text Color="Black" Value="{text}"/>
</Each>
</StackPanel>
</App>
arr here represents the array I’m getting via fetch()
which I’m assigning to the observable by doing fArr.value = arr
. According to your examples I think this should work. Is this now outdated?