Skip to content

Instantly share code, notes, and snippets.

@netguru
Created June 5, 2010 16:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save netguru/426737 to your computer and use it in GitHub Desktop.
Save netguru/426737 to your computer and use it in GitHub Desktop.
class Liquid::Strainer
def is_haml?; false; end
def controller
@controller ||= @context.registers[:controller]
end
delegate :request, :to => :controller
delegate :params, :to => :request
end
@michelson
Copy link

Hi Wiktor, i've saw your post in liquid template google group,
i would like to use this code, but dont work for me,
where do you put this code in a railsapp ? i 've tried to put it in the lib folder, and call the helper like this
{{ @posts | will_paginate}}
but it dont work

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment