Description Usage Arguments Details Value Examples
View source: R/reprex_to_blocks.R
Convert reprex output to slackblocks with text and figure links if relevant
1 |
x |
reprex output |
If a reprex chunk contains an error an rotating_light emoji will be attacheted to the textblock.
slackblocks
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | ## Not run:
if(interactive()){
reprex_to_blocks(
reprex::reprex({
x <- 10
x + 2
},
venue = 'gh',
advertise = FALSE,
show = FALSE)
)
# with plot
reprex_to_blocks(
reprex::reprex({
x <- 10
hist(runif(x))
},
venue = 'gh',
advertise = FALSE,
show = FALSE)
)
# with error
reprex_to_blocks(
reprex::reprex({
x <- 10
hist(runif(2*y))
},
venue = 'gh',
advertise = FALSE,
show = FALSE)
)
}
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.