Fix code snippet in getting started guide (#434)
Description of changes Updates a code snippet from the getting started guide that demonstrated an improper way of disposing of webview panel resources when the panel is closed.
This commit is contained in:
Родитель
b4facb3303
Коммит
bfb9755495
|
@ -157,7 +157,7 @@ With the `dispose` method defined, you also need to update the constructor metho
|
|||
private constructor(panel: vscode.WebviewPanel) {
|
||||
// ... other code ...
|
||||
|
||||
this._panel.onDidDispose(this.dispose, null, this._disposables);
|
||||
this._panel.onDidDispose(() => this.dispose(), null, this._disposables);
|
||||
}
|
||||
```
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче