Skip to content

rstudioapi::executeCommand("viewerClearAll") does not clear viewer pane #294

@HJAllen

Description

@HJAllen

System details

RStudio Edition : Desktop
RStudio Version : 2023.12.0 Build 369
OS Version      : Windows 11
R Version       : 4.3.1

Steps to reproduce the problem

library(ggplot2)
library(plotly)
d <- data.frame(x = 1:10, y = 1:10)
ggplotly(
  ggplot(d) +
  geom_point(aes(x, y)))
rstudioapi::executeCommand("viewerClear")
rstudioapi::executeCommand("viewerClearAll")

Describe the problem in detail

The Posit Workbench Administration Guide lists commands which can be submitted through the rstudioapi including viewerClear and viewerClearAll. When submitting these commands in an attempt to clear the viewer, nothing happens. Other viewer commands like viewerPopout work as expected.

Describe the behavior you expected

Expected behavior is for the viewer pane to be cleared.

  • [X ] I have read the guide for submitting good bug reports.
  • [X ] I have installed the latest version of RStudio, and confirmed that the issue still persists.
  • If I am reporting an RStudio crash, I have included a diagnostics report.
  • [X ] I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions