I need a "GO TO" action NOT TO BE the last action in my workflow (because of setting a state)

Hello, I am designing a “single-page” app for reasons of speed of navigation (it will be published on IOS and Android). Still for the context, I make groups appear and disappear via the action “set state” and a condition “visible” or not depending on the “state”. Everything works well but bubble gives me errors because my “GO TO” are not the last elements. Only, to do that, I need to make a “GO TO” to the same page in order to send data in the URL and to make the display dynamic by retrieving information in the database. And after this “GO TO”, I have a “set state” which allows me to make disappear the groups which should not be displayed anymore… (see attached picture)
How can I do ? How to ignore these errors?

Thank you for your help!

Can you make your question clearer? I tried twice but couldn’t understand what your issue is, other than you wanting to change how Bubble works.

The issue is that after you go to another page, you can’t keep running that WF. So you need to figure out another way. I am not sure I helped much, but no, you can’t ignore errors. Why is flipping your WF around such as issue? It all happens instantly.

Let me try to rephrase:

  • To make groups appear and disappear, I use “set state” to change the state of the parent group
  • After that, the groups I want to make disappear have a condition that says that if the state of the parent group is not the right one, the group is not visible anymore
  • Also, on these groups that I make appear and disappear, I have dynamic elements that change depending on where the user clicks. I don’t know if this is the right way to do it, but to indicate which element to display, I send in the URL the “unique ID” of the element I want to display. And thanks to a “Do a Search” with a constraint, I manage to display the right element.
  • In the work-flow, I first do the “GO TO” then the “set state” because otherwise the “set state” is reset when the page is reloaded
  • Everything works fine ! Only there is the error of Bubble on the order of the actions (see picture)

OK, gotcha. Well you can’t do what you want to do. So just set that state as a URL variable, or adjust the way your logic works on the states you have.

Thanks for your answer! How can I do that? I’m not an expert with Bubble yet :slight_smile:
If it solves my problem, I’ll try!

I’m not sure I understand. You already said you put the unique ID in the URL. So you do know how to. I can’t tell YOU how to adjust YOUR logic though. That’s on you. Sorry,.

Yes thank you for your response.
As you can see my problem and the different things I need to do, have you an idea to solve that problem ? Even if it’s an other workflow or logic…

If you gonna make a single-page app as a native app, avoid using the “go to page” action. Actually, it is not allowed to use this action when you build a native app.

Put any condition on the “Go to page” action that will always be true like Current user is Current user

1 Like

Thank you for your response but I don’t understand for what should I do this ?

Why is it not allowed ? You mean technically or you don’t recommend ?
Because I found a solution for my problem by sending in the url some keywords that show/hide groups with conditions. And it’s working perfectly !

Thank you for your response but I don’t understand for what should I do this ?

I think if you put a condition on the “Go to page” action, the error checker doesn’t care if it’s not the last step anymore. So if you put a condition that would always be true like Current user is Current user then it would still work and not have the error.

Usually those errors are there for a reason though, so if you start to get weird behavior maybe restructure so you’re not needing the “Go to page” action as not the last step

1 Like

Alright, I will test that thank you !
Btw, I found a solution for my problem by sending in the url some keywords that show/hide groups with conditions. And it’s working perfectly !
In the different response from this topic, someone said that “GO TO” for a single page app is not recommended or impossible. Do you know something about that ? Because for me it’s working

I think the “Go to page” action is fine? Unless for some reason you were wrapping your app with wrapper that didn’t recommend it? Personally I like it better because back button works as intended vs custom states it doesn’t really

I need to make a “GO TO” to the same page in order to send data in the URL and to make the display dynamic by retrieving information in the database.

No, even if you send the data prior to the final step ion the workflow it will still work. Think of a workflow as one big set of instructions which will all be actioned regardless of their order.

someone said that “GO TO” for a single page app is not recommended or impossible. Do you know something about that

I use GO TO for my SPA and all works fine.

Thank you for your response ! And congratulations for your SPA, would it be possible to try it ? Is it on IOS ?

Thanks! No, it’s not currently ready, almost but not quite!

Okay no problem I understand :slightly_smiling_face:
Keep me informed when it will be possible to see at least a demo, even if it’s via web

Sure will.