decred / politeiagui

ISC License
62 stars 56 forks source link

[plugins-architecture] Investigate ways to simplify plugins hooks #2774

Closed tiagoalvesdulce closed 2 years ago

tiagoalvesdulce commented 2 years ago

We have some very good and simple hooks but I feel some of them are bloated. IMO the useFetch hooks should:

  1. Trigger a fetch if the status of that request is idle.
  2. Return response, new status and error.
victorgcramos commented 2 years ago

Listeners were a good addition to simplify hooks. Does this issue still need a "fix"?