| orderly_plugin_register | R Documentation |
Create an orderly plugin. A plugin is typically defined by a
package and is used to extend orderly by enabling new
functionality, declared in your orderly configuration
(orderly_config.json) and your orderly file (<name>.R), and
affecting the running of reports primarily by creating new objects
in the report environment. This system is discussed in more
detail in vignette("plugins").
orderly_plugin_register(
name,
config,
serialise = NULL,
deserialise = NULL,
cleanup = NULL,
schema = NULL
)
name |
The name of the plugin, typically the package name |
config |
A function to read, check and process the
configuration section in the orderly configuration. This
function will be passed the deserialised data from the plugin's
section of |
serialise |
A function to serialise any metadata added by the
plugin's functions to the outpack metadata. It will be passed a
list of all entries pushed in via
|
deserialise |
A function to deserialise any metadata
serialised by the |
cleanup |
Optionally, a function to clean up any state that
your plugin uses. You can call |
schema |
Optionally a path, within the package, to a schema
for the metadata created by this plugin; you should omit the
|
Nothing, this function is called for its side effect of registering a plugin.
# The example code from vignette("plugins") is available in the package
fs::dir_tree(system.file("examples/example.db", package = "orderly"))
# See orderly_plugin_register in context here:
orderly_example_show("R/plugin.R", example = "example.db")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.