diff --git a/site/_docs/templates.md b/site/_docs/templates.md index 0ebd35f8..ecb1c110 100644 --- a/site/_docs/templates.md +++ b/site/_docs/templates.md @@ -271,6 +271,26 @@ common tasks easier.

+ + +

Array Filters

+

Push, pop, shift, and unshift elements from an Array.

+ + +

+ {% raw %}{{ page.tags | push: 'Spokane' }}{% endraw %} + {% raw %}{{ page.tags | pop }}{% endraw %} + {% raw %}{{ page.tags | shift }}{% endraw %} + {% raw %}{{ page.tags | unshift }}{% endraw %} +

+

+ ['Seattle', 'Tacoma', 'Spokane'] + ['Seattle', 'Tacoma'] + ['Seattle'] + ['Tacoma'] +

+ +