use_example | R Documentation |
Creates an R script in man/examples
to store examples for a function.
use_example(name = NULL, dir = "man/examples", open = rlang::is_interactive())
name |
Either a name without extension, or |
dir |
The directory where example scripts will be stored.
Defaults to |
open |
Whether to open the file for interactive editing. |
If an example file does not already exist, creates an example file.
If open
is TRUE
, opens the example file.
usethis::use_r()
and usethis::use_test()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.