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

Add pagination to index route #17

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jonahroth
Copy link

Closes #16

Using Kaminari for pagination with 10 changes per page - let me know if that doesn't seem right!

screen shot 2018-03-19 at 1 40 55 pm

@jonahroth jonahroth force-pushed the 16-index-route-pagination branch from 0222300 to 129cd01 Compare April 2, 2018 13:46
Copy link
Owner

@brendanthomas1 brendanthomas1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry this took so long to get to, I've kind of been neglecting this repo. Thanks for help, though! Just one small thing here to get it working with external projects.

@@ -1,5 +1,8 @@
source 'https://rubygems.org'

# Use kaminari for pagination
gem 'kaminari'
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we remove this from here and add it as a dependency in the .gemspec, please? I think you'll need to add a require 'kaminari' in the engine.rb file too.

This seems to work in the dummy app, but it's not working for me in a separate, external rails app that I'm testing in. That doesn't get kaminari on bundle.

remote: data-remote
-%>
<span class="prev">
<%= link_to '<', url, rel: 'prev', remote: remote, class: 'button' %>
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm just trying this out, not a real suggestion

Suggested change
<%= link_to '<', url, rel: 'prev', remote: remote, class: 'button' %>
<%= link_to '<--', url, rel: 'prev', remote: remote, class: 'button' %>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants