How to persist a Full-Stack Signal?

Hi everyone,
I was just reading the documentation about Full-Stack Signals (Creating Full-Stack Signals in Vaadin Applications), which is very good and detailed, by the way :slight_smile:

I was just wondering if there is a recommended way how one should implement the persistence of a Full-Stack Signal? Let’s say I want to store the To-dos in the example of Creating Full-Stack Signals in Vaadin Applications in a database using Spring Data JPA. What would be a good way to do this?

Calling insertLast on a ListSignal in the frontend should result in an insert into a todos table in the backend, for example. Is there some kind of lifecycle, I could hook into to achieve this?

Maybe someone has already implemented something like this and could share some code or a link to a GitHub repo? Thank you in advance.

There’s nothing yet but it’s part of the vision to eventually get there.

For now, the recommendation would be to treat the full-stack signal purely as UI state and have a separate, conventional, data path for having the client make updates to the authoritative business state.

1 Like

OK, thank you, @Leif.