generate_code | R Documentation |
All code necessary for reproducing a data analysis as set up in blockr can
be made available to the user. Several ways of providing such a script or
code snippet are conceivable and currently implemented, we have a modal
with copy-to-clipboard functionality. This is readily extensible, for example
by offering a download button, by providing this functionality as a
generate_code
module.
generate_code(server = generate_code_server, ui = generate_code_ui)
generate_code_server(id, board, ...)
generate_code_ui(id, board)
server , ui |
Server/UI for the plugin module |
id |
Namespace ID |
board |
The initial |
... |
Extra arguments passed from parent scope |
A plugin container inheriting from generate_code
is returned by
generate_code()
, while the UI component (e.g. generate_code_ui()
) is
expected to return shiny UI (i.e. shiny::tagList()
) and the server
component (i.e. generate_code_server()
) is expected to return NULL
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.