Skip to content

Instantly share code, notes, and snippets.

@michalkorzawski
Created August 15, 2022 14:13
Show Gist options
  • Save michalkorzawski/fb94e529b58869afe529152312f32093 to your computer and use it in GitHub Desktop.
Save michalkorzawski/fb94e529b58869afe529152312f32093 to your computer and use it in GitHub Desktop.
# FilterReflex#results
page = element.href&.split('=')&.last&.to_i || 1
# And pass it to pagy collection
pagy, collection = pagy(active_record_collection, page: page)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment