Skip to content

Commit

Permalink
Enable optiojn to retain webview state for side-panel mode (#43)
Browse files Browse the repository at this point in the history
This option makes it so that when switching between different panels in
side panel (i.e. file explorer <> IDE), the IDE wouldn't reset its
webview state.
  • Loading branch information
kmagiera authored Mar 27, 2024
1 parent a22d530 commit b248a9b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/vscode-extension/src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ export async function activate(context: ExtensionContext) {
context.subscriptions.push(
window.registerWebviewViewProvider(
SidePanelViewProvider.viewType,
new SidePanelViewProvider(context)
new SidePanelViewProvider(context),
{ webviewOptions: { retainContextWhenHidden: true } }
)
);
context.subscriptions.push(commands.registerCommand("RNIDE.openPanel", showIDEPanel));
Expand Down

0 comments on commit b248a9b

Please sign in to comment.