Simple Lazy Loading in Rails with Hotwire and Turbo Frames (12 Lines of Code)
railsnotes.xyz
railsnotes.xyz
This posts illustrates some of my favourite things about modern Ruby on Rails — dynamic frontends, powerful functionality, and very short and succinct implementations.
This lazy loader is basically just a few Turbo Frames sprinkles into our views, but they do the job and they do it well.
Happy to answer any questions you might have too.
Thanks, Harrison