Hi,
I’m currently working on a Chrome extension, where the content script will use window.postMessage
to post message and on my Shiny App side I have javascript code window.addEventListener("message", function(event) {handleEvent(event)})
. When I tested running the standalone Shiny app without shinyproxy everything works fine, but when I embedded my app into shinyproxy, my app could not receive the message anymore.
One thing I’m suspecting is that accessing the DOM element window has a different meaning when using shinyproxy because I saw it’s using a iframe whose id is “shinyframe” to wrap all the Shiny UI.
Is there any way that I can still send message from a chrome extension injected javascript page to my Shiny Apps DOM, so the customized javascript code resides on the Shiny App will be able to handle the event?
Appreciate your help!