create_input_binding | R Documentation |
Creates a script in inst and the R part in ./R
create_input_binding( name, pkg = ".", dir = "srcjs", open = TRUE, initialize = FALSE, dev = FALSE, events = list(name = "click", rate_policy = FALSE), add_reference = TRUE ) create_output_binding( name, pkg = ".", dir = "srcjs", open = TRUE, add_reference = TRUE ) create_custom_handler( name, pkg = ".", dir = "srcjs", open = TRUE, add_reference = TRUE ) create_js( name, dir = "srcjs", open = TRUE, with_doc_ready = FALSE, template = golem::js_template, ..., add_reference = TRUE ) create_scss( name, dir = "styles", open = TRUE, template = golem::sass_template, ..., add_reference = TRUE )
name |
The name of the module. |
pkg |
Path to the root of the package. Default is |
dir |
Path to the dir where the file while be created. |
open |
Should the created file be opened? |
initialize |
For JS file - Whether to add the initialize method. Default to FALSE. Some JavaScript API require to initialize components before using them. |
dev |
Whether to insert console.log calls in the most important methods of the binding. This is only to help building the input binding. Default is FALSE. |
events |
List of events to generate event listeners in the subscribe method.
For instance, |
add_reference |
Whether to add an import statement in main.js. Defaults to TRUE. |
with_doc_ready |
For JS file - Should the default file include |
template |
Function writing in the created file. You may overwrite this with your own template function. |
... |
Arguments to be passed to the |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.