When you implement the environment interface it is encouraged to use actions to signal resolved requests.
In React the term action is conflated in the sense that it represents both an action, like SIGN_IN, and events, like LOAD_DATA_SUCCESS. We decided to rather embrace this conflated term instead of trying to shift a very established mindset. This ensures consistent typing and naming things is hard enough, forcing events and past tense naming is unrealistic.
Now we are not returning anything, but calling fetchSandbox will result in one of two actions. Doing this does not only comply better with Reacts behaviour, but gives several other benefits:
Features does not have to translate the result of the Promise into an action, all actions from the subscription is passed into the feature to possibly be handled
Environment effects can emit actions synchronously and asynchronously
Environment effects can emit multiple actions. This can be related to caching, lazy updating and/or automatically subscribing to the data
You get typed errors
Tests no longer needs to run asynchronously as the responses can be triggered as synchronous actions
There are many opportunities to optimize how effects deals with over fetching, caching etc.
Prevent unnecessary requests
Only do a single fetch for any item requested at any time.