class Liquid::Break
Break tag to be used to break out of a for loop.
Basic Usage:¶ ↑
{% for item in collection %}
{% if item.condition %}
{% break %}
{% endif %}
{% endfor %}
Constants
- INTERRUPT
Public Instance Methods
render_to_output_buffer(context, output)
click to toggle source
# File lib/liquid/tags/break.rb, line 16 def render_to_output_buffer(context, output) context.push_interrupt(INTERRUPT) output end