coatless / quarto-webr

Community developed Quarto Extension to Embed webR for HTML Documents, RevealJS, Websites, Blogs, and Books.
https://quarto-webr.thecoatlessprofessor.com/
394 stars 19 forks source link

Can webr and shinylive work together in a quarto document? #167

Closed royfrancis closed 8 months ago

royfrancis commented 8 months ago

What's your question?

Shinylive and webr quarto extensions seem to work when used independently. But, if I include both of them in the same document, only webr works. Is that expected behavior?

royfrancis commented 8 months ago

Never mind! It seems to be working in a clean new environment. It is probably something to do with my project.

coatless commented 8 months ago

Yes, the {quarto-shinylive} and {quarto-webr} extension should be embeddable and work together in harmony in the same document. However, they will use different webR instances since shinylive applications are sandboxed to their application and will not share any variables.

Here's a MWE that shows a shinylive app via {quarto-shinylive} working alongside of {quarto-webr}:

https://github.com/coatless-tutorials/quarto-webr-with-quarto-shinylive