I'm learning how to use ractive and can't solve a problem, the code is at the following jsfiddle.
The gist of what I'm doing is counters for a queue (last object in array is current person): 1. A counter to display the queue number of the current person 2. A counter to display the size of the queue
A) works correctly but it is bloated with logic so I tried to convert it into a separate variable, as shown in B) but it doesn't update at all.
I put an observer in the code to watch when there is any change to the queue variable. I expect it to show an alert every time I click on "skip current person" or "delete current person" but the alert only shows up in the first time I load the page.
ractive.observe({
'queue.0.queueNo': alert('here')
});