ref: update owl.js, use componentdidupdate

This commit is contained in:
Géry Debongnie
2019-04-01 16:00:50 +02:00
parent 89e6a00d3e
commit 213c83bab5
2 changed files with 20 additions and 8 deletions
+1 -3
View File
@@ -59,13 +59,11 @@ class TabbedEditor extends Component {
});
}
updateProps() {
const result = super.updateProps(...arguments);
componentDidUpdate() {
if (this.editor) {
window.dispatchEvent(new Event("resize"));
this.editor.setValue(this.props[this.state.currentTab], -1);
}
return result;
}
willUnmount() {