Hi everyone!
I’ve recently started using WeWeb and so far have been really enjoying it! However I hit a snag that I am not sure how to solve…
For context, in a project I’ve been developing I decided to create a multidrop component to use in several places and this component has an exposed “value” variable that houses its current value and a “initial_value” property that defines the initial value this variable should have.
To implement this initial value I created a workflow that sets the variable “value” to the “initial_value” property and call it with the On Mounted event of the component.
Now, the issue comes when I have an instance of the component where the initial value is a collection. I suspect that whats happening in this case is that my On Mounted workflow runs before the collection is loaded and as a result the initial_value is empty when its supposed to be loaded on the current value variable.
I was able to get around this issue by calling the workflow with the On Page load event, but thats not ideal as it means I will have to set up this workflow on every page that has the component and call it for every instance, which is just kind of clunky.
So my questions is: is there any way to make sure this workflow runs only after the collection finished loading? Or any other way of doing this exact same thing I am trying?
I Thanks to everyone in advance!