Bubble’s Option set in weweb (with variables)

Hello there,

Coming from bubble, I’m basically wondering how I could use an equivalent of “option-sets

Let me explain. It’s a very simple use case.

Let’s say I have a list of 3 categories, (Sales question, product info, Bug)

I want to display them programmatically, in a list, avoiding me to :

  • misspell a category name
  • Add or remove categories in one place, without having to modify the UI each time.

When I click a category, I want the ‘category’ to be “selected”, and show the user a different UI, when selected.

Back to bubble.
Bubble’s Option-set are stored on the client’s browser, but act a bit like database.

So in weweb, I guess, I could create my categories in the database, like a classic table…
But I was thinking of using variables to solve my issue.

Question :
was that clear ?
If so, do you have a solution ?

The solution for people reading:
Have one array variable “category-list”.
And one object variable “stelected-category”

On click of the category div, just change the variable.
and bind the UI elements to that variable.

category-list

[
    {
        "category": "Sales Question",
        "description": "Happy to clarify anything you like"
    },
    {
        "category": "Product Information",
        "description": "Always fortunate to hear from you"
    },
    {
        "category": "Bug",
        "description": "We will do our best to fix them"
    }
]

Yes, this is the right way of doing this. Good job, you made a great decision ditching Bubble.

1 Like

I’d say that I’m opening my options for now :sweat_smile:.

I really like the simplicity of WeWeb that actually seems faster than I though to build on…
Let’s see with time with a more in-depth comparison how I get on