Are rows of an Observable array Observables themselves?

I have an Observable array called Event and it has several rows with additional information like id, name, type, etc…
The UX uses these rows in a form where the user can edit them (Value="{Event.name}", Value="{Event.type}", …). But when looking at the Event Observable after changing {Event.address} from e.g. “Someplace 3” to “Otherplace 4” it still says “Someplace 3”. So I’m wondering if rows of Observable arrays are also subscribed Observables or static outputs to be used in UX but not manipulated in JS after changes in UX? If so, is there a way to make them change in JS as well when manipulated in UX, still using Event as ‘source’ and not create one Observable for each row?

Thanks in advance.

Hi ferdinand,

in the sense you’re asking, no they are not. List Observables notify their subscribers about changes to their items when the entire item gets updated, not when a property of an item gets updated.

So if you want to avoid creating nested Observables, you could do something like this in a callback:

var tmp = list.getAt(index); // index of the list item being edited
tmp.address = "The new address";
list.replaceAt(index, tmp); // put it back where you found it

Hope this helps!

Ok I see, thank you.
I was hoping to use only one variable (Event) instead of defining every child as independent Observables to save some space in the code, but that’ll do until another option may come in the future.