tshaddix / webext-redux

A set of utilities for building Redux applications in Web Extensions.
MIT License
1.22k stars 180 forks source link

await proxy store aliased action's result #239

Open wswoodruff opened 4 years ago

wswoodruff commented 4 years ago

I looked around in the docs and issues and might have missed it, but couldn't find a solution to provide me with an aliased action's result in a proxy store.

As I learn how to work in this distributed area, to avoid headache and to ensure I know where state is, I've forced all proxy store actions to be aliased.

Normally my actions return an array for [err, result] — I deal with that in the dispatchResponder for my background store — but I'd like to await for [err, result] in my containers.

The intention is for giving user feedback when they, ex: click a login button. We want to tell the user if there was an error, or we want to clear the form and route to another page or show a success message or whatever.

jlalmes commented 3 years ago

I made this PR - does the solve the issue you are describing? https://github.com/tshaddix/webext-redux/pull/262