nx10 / httpgd

Asynchronous http server graphics device for R.
https://nx10.github.io/httpgd
GNU General Public License v2.0
377 stars 19 forks source link

Client sidebar preview not fully updating for complex plots #78

Open nx10 opened 2 years ago

nx10 commented 2 years ago

Describe the bug

The preview images of the JS client do not fully update when a complex plot is drawn.

To Reproduce

n <- 1000
df <- data.frame(
  x=rnorm(n), 
  y=rnorm(n), 
  group=sample(1:4, n, replace=T), 
  color=sample(1:4, n, replace=T), 
  facet=sample(1:4, n, replace=T))
library(ggplot2)
ggplot(df, aes(x=x, y=y, group=group, color=color)) +
  geom_line() + facet_wrap(~ facet)

Expected behavior

The preview tiles should show a complete version of each plot.

Screenshots

chrome_kEtospTMWM