diff --git a/lib/will_paginate/view_helpers/link_renderer.rb b/lib/will_paginate/view_helpers/link_renderer.rb index 5eb52a279..3b7769bc6 100644 --- a/lib/will_paginate/view_helpers/link_renderer.rb +++ b/lib/will_paginate/view_helpers/link_renderer.rb @@ -92,6 +92,9 @@ def link(text, target, attributes = {}) target = url(target) end attributes[:href] = target + if @options[:ajax] + attributes["data-remote"] = true + end tag(:a, text, attributes) end