Comments (12)
Thanks. FYI, if you are OK with the screenshots, using webshot is more handy.
https://bookdown.org/yihui/bookdown/html-widgets.html
For example, this should work (after you install PhantomJS by webshot::install_phantomjs()
):
---
title: "plot.ly test"
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(
echo = TRUE,
screenshot.force = TRUE
)
```
## plot.ly test
```{r plotly}
library(plotly)
plot_ly(economics, x = ~pop)
```
from conflr.
from conflr.
I think Confluence doesn't allow you to embed plot.ly. Can you?
from conflr.
I guess there is no easy way of embedding the plotly JavaScript object in confluence… Will look a bit more into if that's possible
A simple workaround would be turning the plotly item into a png, that's then included in the markdown like below.
`
p = plotly::plot_ly(pressure, x = ~temperature, y = ~pressure, mode = 'type', type = 'scatter')
plotly::orca(p, "tmp.png")
knitr::include_graphics("tmp.png")
`
The above deploys the image to our company confluence page using conflr. Not a pretty solution, though… And would require an installation of the orca command line program on the user side https://github.com/plotly/orca and version
from conflr.
Excellent advice - many thanks!
from conflr.
FYI some people in my company are using plotly in confluence and it is totally reactive. People put things in an iframe to make it work
from conflr.
Yeah, if HTML macro is available, it's possible. But, I don't think it's not always the case.
HTML macros are disabled by default
https://confluence.atlassian.com/doc/html-macro-38273085.html
Unfortunately, I don't have access to a Confluence with HTML macro enabled... Do you want to try a PR for this feature?
from conflr.
@statquant
Can you share us the full HTML code?
from conflr.
Hello @yutannihilation if you can drive me a bit I'd like to try to PR this, I think that would really make a huge difference to this package and our work flow in general. I have access to confluence with html macro
from conflr.
A PR for this will be really appreciated!
from conflr.
Would you have some tips and pointers to get me started ?
from conflr.
Sorry, I don't have much time to write some developer guide... I guess you can add something like replace_htmlwidgets()
in this function:
Line 12 in 38143bb
from conflr.
Related Issues (20)
- Error after rendering HOT 4
- error during uploading of images HOT 1
- How can I publish R package documentation to confluence HOT 4
- Issue 'Base URL of Confluence API' "Error : ! Invalid credentials" RStudio HOT 2
- post to confluence from html HOT 3
- Including interactive network map with visNetwork? HOT 1
- Error rendering macro 'code' HOT 1
- Is it possible to programmatically untick "notify watchers" when posting to confluence? HOT 3
- `code_folding: hide` is not folding code HOT 2
- 403 forbidden HOT 3
- read html file as `body` in `conflr::confl_update_page()` HOT 2
- Rmarkdown upload with interactive plots HOT 2
- Fix for inline maths/ list elements not getting translated
- Invalid credentials / no access with personal access token
- add R markdown template
- Quarto support HOT 1
- Links to headings
- How to create links to top of the document?
- scrollbars on wide tables? HOT 1
- DT::datatable only shows header HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from conflr.