We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d882f2d commit dfddbb6Copy full SHA for dfddbb6
tests/index.js
@@ -11,8 +11,12 @@ import './lib';
11
12
// There’s no DOM available during the tests and the error stack is just a stub
13
// that don’t need to be mapped.
14
+RedBoxError.prototype.mapOnConstruction = function(error) {
15
+ this.state = { error, mapped: true }
16
+}
17
+
18
RedBoxError.prototype.mapError = function(error) {
- this.state = { error }
19
+ this.setState({ error, mapped: true })
20
}
21
22
const beforeEach = (framesStub) => {
0 commit comments