Skip to content

Document splicing argument in theme() #5790

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Mar 21, 2024
Merged

Conversation

olivroy
Copy link
Contributor

@olivroy olivroy commented Mar 21, 2024

Attempt to document better #5543

@teunbrand
Copy link
Collaborator

Thanks for the PR! Should we mention the splicing option for aes() too?

Co-authored-by: Teun van den Brand <[email protected]>
@olivroy
Copy link
Contributor Author

olivroy commented Mar 21, 2024

Thanks for the suggestion.

I don't think it is worth bothering with aes(). Here is how it is currently documented:

#' @param x,y,... <[`data-masking`][rlang::topic-data-mask]> List of name-value
#'   pairs in the form `aesthetic = variable` describing which variables in the
#'   layer data should be mapped to which aesthetics used by the paired
#'   geom/stat. The expression `variable` is evaluated within the layer data, so
#'   there is no need to refer to the original dataset (i.e., use
#'   `ggplot(df, aes(variable))` instead of `ggplot(df, aes(df$variable))`).
#'   The names for x and y aesthetics are typically omitted because they are so
#'   common; all other aesthetics must be named.

Also, the upcoming version of RStudio will no longer show ... in autocompletion for aes(). rstudio/rstudio#8444

@teunbrand
Copy link
Collaborator

I don't think it is worth bothering with aes().

Fair enough. If you could hit devtools::document() to populate the .Rd file, I think this should be good to go.

@olivroy olivroy changed the title Update theme.R Document splicing argument in theme() Mar 21, 2024
Copy link
Collaborator

@teunbrand teunbrand left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution!

@teunbrand teunbrand merged commit a90e8ed into tidyverse:main Mar 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants