mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-15 08:50:45 -07:00
Add docs for at_least and at_most filters
This commit is contained in:
@@ -0,0 +1,34 @@
|
|||||||
|
---
|
||||||
|
title: at_least
|
||||||
|
description: Liquid filter that limits a number to a minimum value
|
||||||
|
---
|
||||||
|
|
||||||
|
Limits a number to a minimum value.
|
||||||
|
|
||||||
|
<p class="code-label">Input</p>
|
||||||
|
{% raw %}
|
||||||
|
```liquid
|
||||||
|
{{ 4 | at_least: 5 }}
|
||||||
|
```
|
||||||
|
{% endraw %}
|
||||||
|
|
||||||
|
<p class="code-label">Output</p>
|
||||||
|
{% raw %}
|
||||||
|
```
|
||||||
|
5
|
||||||
|
```
|
||||||
|
{% endraw %}
|
||||||
|
|
||||||
|
<p class="code-label">Input</p>
|
||||||
|
{% raw %}
|
||||||
|
```liquid
|
||||||
|
{{ 4 | at_least: 3 }}
|
||||||
|
```
|
||||||
|
{% endraw %}
|
||||||
|
|
||||||
|
<p class="code-label">Output</p>
|
||||||
|
{% raw %}
|
||||||
|
```
|
||||||
|
4
|
||||||
|
```
|
||||||
|
{% endraw %}
|
||||||
@@ -0,0 +1,34 @@
|
|||||||
|
---
|
||||||
|
title: at_most
|
||||||
|
description: Liquid filter that limits a number to a maximum value
|
||||||
|
---
|
||||||
|
|
||||||
|
Limits a number to a maximum value.
|
||||||
|
|
||||||
|
<p class="code-label">Input</p>
|
||||||
|
{% raw %}
|
||||||
|
```liquid
|
||||||
|
{{ 4 | at_most: 5 }}
|
||||||
|
```
|
||||||
|
{% endraw %}
|
||||||
|
|
||||||
|
<p class="code-label">Output</p>
|
||||||
|
{% raw %}
|
||||||
|
```
|
||||||
|
4
|
||||||
|
```
|
||||||
|
{% endraw %}
|
||||||
|
|
||||||
|
<p class="code-label">Input</p>
|
||||||
|
{% raw %}
|
||||||
|
```liquid
|
||||||
|
{{ 4 | at_most: 3 }}
|
||||||
|
```
|
||||||
|
{% endraw %}
|
||||||
|
|
||||||
|
<p class="code-label">Output</p>
|
||||||
|
{% raw %}
|
||||||
|
```
|
||||||
|
3
|
||||||
|
```
|
||||||
|
{% endraw %}
|
||||||
Reference in New Issue
Block a user