()
| 60 | } |
| 61 | |
| 62 | componentDidMount() { |
| 63 | window.onmessage = (e) => { |
| 64 | this.runApplication(e.data) |
| 65 | } |
| 66 | |
| 67 | window.onerror = (message, source, line) => { |
| 68 | line -= prefixLineCount |
| 69 | this.throwError(`${message} (${line})`) |
| 70 | return true |
| 71 | } |
| 72 | |
| 73 | parent.postMessage(JSON.stringify({ |
| 74 | id: this.props.id, |
| 75 | type: 'ready', |
| 76 | }), '*') |
| 77 | } |
| 78 | |
| 79 | buildErrorMessage(e) { |
| 80 | let message = `${e.name}: ${e.message}` |
nothing calls this directly
no test coverage detected