-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Better error reporter interface (#61)
We were a bit hasty with the changes that were made to v2.0.0! It seems prudent to circle back and make a few improvements: Reverts the default behavior to throwing the error instead of printing it (this aligns better with expectations from Rodux 1.x) Don't inherit the deferred and immediate abstraction from external codebases. Instead, categorize errors into ones that occur when processing actions with reportReducerError (running reducers on dispatched actions) and ones that occur when updating listeners with reportUpdateError (flushing new state) For the error reporter interface, provide a set of data relevant to each situation. This includes recent actions, store state, and the thrown error Removes error reporting from signal, to try to keep it simple and generic; most usage of rodux is through helper libraries that manage the signal connections, anyway. Updates tests to account for new expected behavior Carves out some overzealous printing logic; users of the error reporter API can opt into it isntead
- Loading branch information
1 parent
c9b9807
commit d0c21a7
Showing
9 changed files
with
331 additions
and
391 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.