add destroy event

This commit is contained in:
Philipp Kühn
2020-11-30 13:50:06 +01:00
parent 6f3517a5cf
commit 6c39aea432
7 changed files with 33 additions and 5 deletions

View File

@@ -385,6 +385,8 @@ export class Editor extends EventEmitter {
* Destroy the editor.
*/
public destroy() {
this.emit('destroy')
if (this.view) {
this.view.destroy()
}