appsmithorg / appsmithorg/appsmith
[Feature]-[500]:Reactive Actions Setting, execute actions when dependencies change
- Vorherrschende Sprache
- TypeScript
- Sterne
- 40.9k
- Forks
- 4.8k
- Ø Merge
- 1 T. 22 Std.
- Gemergte PRs (30 T.)
- 45
Beschreibung
## Description
We need a feature to allow the execution of actions whenever one of their dependent values changes. This will mean that an API / Query that reads a value from a widget or from another API/Query will be automatically re-run whenever the value of the Widget/API/Query changes. ex.
fetchUsersAPI
Body: {{Input1.text}}
This will call fetchUsers API whenever a user types a value in Input1
This feature should be an explicit setting that users must enable to begin with. If we see mass adoption and benefit here, we can introduce the logic to auto enable this for non-destructive actions the way we do for the onPageLoad setting
## Motivation
- This will make it easier for users to configure apps since it adheres more closely to the reactive paradigm and users now need only focus on the relationships between entities. We see this often where users configure pagination perfectly only to miss out on the last step i.e calling the API onPageChange. Related to #2086 and #2341
- This allows us to configure workflows where onPageLoad, we can call 1 API which fetches the list of users and another API to fetch the details of the first user in the table using the table's default selected row property. This is not possible today because the fetchDetails API is run before the table.selectedRow can be updated with the details of the fetchUsers API.
Beitragsleitfaden
Bewertung
Dieses Issue wurde noch nicht bewertet.