Overlay Modal Priority

state changes within retool are async.

My understanding for the reason this happens (potentially confusingly) with variables is that when you update a variable the app needs to

  1. propogate this state change across the app
  2. trigger dependent queries
  3. update the UI

because of this. if you want to immediately utilize that value change, you need to await the setting of the value.

alternatively, in your query you could add an additional scope (add tId in {{ }} in your query)

getTs.trigger({additionalScope: {
   tId: project.tId}
   }
});

hope that clears things up

1 Like