Safely dispose of editor
This commit is contained in:
parent
18f45fe241
commit
2f93d167a1
|
|
@ -162,7 +162,10 @@ export class ElsaMonaco {
|
|||
}
|
||||
|
||||
disconnectedCallback() {
|
||||
this.editor.dispose();
|
||||
const editor = this.editor;
|
||||
|
||||
if (!!editor)
|
||||
editor.dispose();
|
||||
}
|
||||
|
||||
registerLiquid() {
|
||||
|
|
|
|||
Loading…
Reference in a new issue