1
0
mirror of https://github.com/chinchang/web-maker.git synced 2025-07-28 09:10:17 +02:00

fix expr evaluation in child frame

This commit is contained in:
Kushagra Gour
2019-02-28 18:29:04 +05:30
parent 956eeb3cc4
commit a86ac7ca47
3 changed files with 11 additions and 2 deletions

View File

@@ -69,6 +69,8 @@ export default class ContentWrap extends Component {
}
componentDidMount() {
this.props.onRef(this);
// Listen for logs from preview frame
window.addEventListener('message', e => {
if (e.data && e.data.logs) {
this.onMessageFromConsole(...e.data.logs);