We are here again with some new information about Ruby gems. Pagy 2.0 is the ultimate pagination Ruby gem. Works with all Rack-based frameworks and is storage/ORM agnostic. 2.0 improves i18n support, is faster, and works on more versions of Ruby than before.
Improvements in v2.0+
- Lower ruby requirements (ruby v1.9+ || jruby v1.7+) make Pagy very convenient also on older systems
- Added RFC-8288 compliant http response
- The i18n internal implementation now includes full dynamic support for multi-language apps, it’s ~18x faster and uses ~10x less memory than the i18n gem
elasticsearch_railsextras have been refactored with more and better options
- Pagy v2.0+ is even faster and lighter than v1.0+
Unlike the other gems
- Pagy is very modular and does not load nor execute unnecessary code in your app
- It works even with collections/scopes that already used
- It works with helpers or templates
- It raises real
Pagy::OverflowErrorexceptions that you can rescue from or use the overflow extra for a few ready to use common behaviors
- It does not impose any difficult-to-override logic or output
- It also works on legacy systems starting from ruby v1.9+ and jruby v1.7+
Check here for more details. We also included Pagy 2.0 to our list of the most popular Rails repositories on GitHub.
And some good news that you shouldn’t miss! RubyGems updated due to some vulnerabilities, so we recommend you change it to the latest stable version.