Closed mihirasaraswati closed 7 years ago
aye. Shiny does it's own "thing" with widget id's which is somewhat frustrating given how multiple metricsgraphics widgets can be linked together automagically but also understandable since Shiny does much more automagically for developers. i haven't heard of it causing issues with Shiny apps, but you may not be able to easily link metricsgraphics charts together in a Shiny context.
This is still ugly, but if you provide an elementId
argument to the mjs_plot
in lines, and then accept that if provided in lines, you would still get the warning, but linking could still occur for advanced users. In a Shiny context, a user will be required to assign an id
, so we know each metricsgraphicsOutput
will have a hopefully unique id
.
Well I only have one graph so no linking is required... I've added options(warn =-1) to my server function and that has done the "trick". Thanks for the assist.
Workaround: https://github.com/ropensci/plotly/issues/985
I've built a shiny application that uses metricsgraphics to create histogram. When running the application I get the following error message:
Warning in output$histPlot(...) : Ignoring explicitly provided widget ID "mjs-acd1c2bc860bf1a81780a7603d6f7b"; Shiny doesn't use them
My app can be run with the following command:
shiny::runGitHub(repo = 'mihiriyer/mental')
My code is located here: https://github.com/mihiriyer/mental/blob/master/app.R
The app seems to work fine and so should I even be worried since it is just a warning? Should I just suppress the message and move on?