Description Usage Arguments Value Examples
View source: R/Snippet_Pipe_Check.R
Decides whether or not to insert a pipe as well during snippet insertion.
1 | snippet_pipe_check(afterStr = "", elseStr = "", pipeStr = "%>% ")
|
afterStr |
Text to insert after the pipe (character scalar). |
elseStr |
Text to insert if no pipe is needed (character scalar). |
pipeStr |
The pipe to insert if needed (character scalar). |
The deleted code (character scalar).
1 2 3 4 5 6 7 | # Set up a snippet as:
# snippet mu
# `r KO:::snippet_pipe_check();`mutate(${0})
# Then type "mtcars mu", & run the add-in function
# Or type "mtcars %>% mu", & run the add-in function
# The output for both will be "mtcars %>% mutate()"
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.