Skip to content
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

Fix tibble-like printing in vignette #732

Open
urswilke opened this issue Mar 22, 2025 · 0 comments
Open

Fix tibble-like printing in vignette #732

urswilke opened this issue Mar 22, 2025 · 0 comments
Labels
help wanted ❤️ we'd love your help!

Comments

@urswilke
Copy link

in https://github.com/r-lib/pillar/blob/main/vignettes/extending.Rmd, the statement in

The `"default"` class doesn't have any customizations yet, and prints like a regular tibble.
is not correct (it doesn't print like a regular tibble).

If I pass NULL instead of "default" it works:

library(pillar)

example_tbl <- function(class) {
    vctrs::new_data_frame(
        list(
            a = letters[1:3],
            b = data.frame(c = 1:3, d = 4:6 + 0.5)
        ),
        class = c(class, "tbl")
    )
}
example_tbl(NULL)
#> # A data frame: 3 × 2
#>   a       b$c    $d
#>   <chr> <int> <dbl>
#> 1 a         1   4.5
#> 2 b         2   5.5
#> 3 c         3   6.5
@krlmlr krlmlr added the help wanted ❤️ we'd love your help! label Mar 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted ❤️ we'd love your help!
Projects
None yet
Development

No branches or pull requests

2 participants