Skip to content

Feature request: Set the current facet_*_paginate page without calling the facet function again #339

@billdenney

Description

@billdenney

In humanpred/ggtibble#2, I'm trying to make a generic conversion from the facet_*_paginate uses to a list of figures (similar to what is in #219). A challenge with this is that I only know how to update the page by calling facet_*_paginate again with a new page number.

I think that it's as simple as updating p$facet$params$page <- 2 (where p is the original figure and 2 is the new page number desired), but I hesitate to reach that deeply into the facet settings in case something changes in the future.

Would it be reasonable to create something like a set_facet_page() function that could possibly be as simple as:

set_facet_page <- function(p, page) {
  p$facet$params$page <- page
  p
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions