Liquid Filters Reference for DocOps Lab Projects
This document is intended for AI agents operating within a DocOps Lab environment.
Custom AsciiSourcerer/DocOps Lab filters are located under ## Filters from AsciiSourcerer below.
Filters from Jekyll
- Date to XML Schema (
date_to_xml_schema) -
Convert a Date into XML Schema (ISO 8601) format.
Category Date Formatting
- Examples
-
Input
{{ "2008-11-07 1:07:54pm" | date_to_xmlschema }}Output2008-11-07T13:07:54-08:00
- Date to RFC-822 Format (
date_to_rfc822) -
Convert a Date into the RFC-822 format used for RSS feeds.
Category Date Formatting
- Examples
-
Input
{{ data.time | date_to_rfc822 }}OutputFri, 07 Nov 2008 13:07:54 -0800
- Date to String (
date_to_string) -
Convert a date to short format.
Category Date Formatting
- Examples
-
Input
{{ data.time | date_to_string }}Output07 Nov 2008Input{{ data.time | date_to_string: "ordinal", "US" }}OutputNov 7th, 2008
- Date to Long String (
date_to_long_string) -
Format a date to long format.
Category Date Formatting
- Examples
-
Input
{{ data.time | date_to_long_string }}Output07 November 2008Input{{ data.time | date_to_long_string: "ordinal" }}Output7th November 2008
- Where (
where) -
Select all the objects in an array where the key has the given value.
Category Array Selection
- Examples
-
Input
{% assign filtered = data.users | where:"level", 2 %} {{ filtered | size }}Output1Input{% assign member = data.users | where:"user","alice" %} {{ member[0] | jsonify }}Output{"user":"alice","level":1}
- Where Expression (
where_exp) -
Select all the objects in an array where the expression is true.
Category Array Selection
- Examples
-
Input
{{ data.members | where_exp:"item", "item.grad_year == 2014" | jsonify }}Output[{"user":"andie","grad_year":2014,"projects":["fooman","barbaz"]},{"user":"lonnie","grad_year":2014,"projects":["fooman"]}]Input{{ data.members | where_exp:"item", "item.grad_year < 2014" | jsonify }}Output[{"user":"cindy","grad_year":2012,"projects":["fooman","foobar"]}]Input{{ data.members | where_exp:"item", "item.projects contains 'barbaz'" | jsonify }}Output[{"user":"andie","grad_year":2014,"projects":["fooman","barbaz"]}]
- Group By (
group_by) -
Group an array’s items by a given property.
Category Array Organizing
- Examples
-
Input
{% assign grouped = data.members | group_by:"grad_year" | first %} {{ grouped.name }}Output2014
- Group By Expression (
group_by_exp) -
Group an array’s items using a Liquid expression.
Category Array Organizing
- Examples
-
Input
{{ data.members | group_by_exp: "item", "item.grad_year" | map: "name" | join: "," }}Output2014,2012
- XML Escape (
xml_escape) -
Escape some text for use in XML.
Category String Escaping
- Examples
-
Input
{{ "<strong>some text</strong>" | xml_escape }}Output<strong>some text</strong>
- CGI Escape (
cgi_escape) -
CGI escape a string for use in a URL. Replaces any special characters with appropriate
%XXreplacements. CGI escape normally replaces a space with a plus+sign.Category String Escaping
- Examples
-
Input
{{ "foo, bar; baz?" | cgi_escape }}Outputfoo%2C+bar%3B+baz%3F
- URI Escape (
uri_escape) -
Percent encodes any special characters in a URI. URI escape normally replaces a space with
%20. Reserved characters will not be escaped.Category String Escaping
- Examples
-
Input
{{ "http://foo.com/?q=foo, \bar?" | uri_escape }}Outputhttp://foo.com/?q=foo,%20%5Cbar?
- Number of Words (
number_of_words) -
Count the number of words in a text.
Category String Analysis
- Examples
-
Input
{{ page.content | number_of_words }}Output3
- Array to Sentence (
array_to_sentence_string) -
Convert an array into a sentence. Useful for listing tags. Optional argument for connector.
Category Object Conversion
- Examples
-
Input
{{ tags_array | array_to_sentence_string }}Outputfoo, bar, and bazInput{{ tags_array | array_to_sentence_string: "or" }}Outputfoo, bar, or baz
- Data To JSON (
jsonify) -
Convert Hash or Array to JSON.
Category Object Conversion
- Examples
-
Input
{{ tags_array | jsonify }}Output["foo","bar","baz"]
- Normalize Whitespace (
normalize_whitespace) -
Replace any occurrence of whitespace with a single space.
Category String Conversion
- Examples
-
Input
{{ "a b" | normalize_whitespace }}Outputa b
- Sort (
sort) -
Sort an array. Optional arguments for hashes 1. property name 2. nils order (first or last).
Category Array Organizing
- Examples
-
Input
{{ page.tags | sort | inspect }}Output["Seattle", "Spokane", "Tacoma"]Input{{ site.posts | sort: "author" }}Input{{ site.pages | sort: "title", "last" }}
- Sample (
sample) -
Pick a random value from an array. Optionally, pick multiple values.
Category Array Selection
- Examples
-
Input
{{ site.pages | sample }}Input{{ site.pages | sample: 2 }}
- To Integer (
to_integer) -
Convert a string or boolean to integer.
Category Object Conversion
- Examples
-
Input
{{ true | to_integer }}Output1Input{% assign five = "5" | to_integer %} {% if five == 5 %}Samesies!{% endif %}OutputSamesies!Input{{ "five" | to_integer }}Output0
- Push (
push) -
Insert an item at the end of an array
Category Array Management
- Examples
-
Input
{{ page.tags | push: "Spokane" | inspect }}Output["Seattle", "Tacoma", "Spokane", "Spokane"]
- Pop (
pop) -
Remove an item from the end of an array
Category Array Management
- Examples
-
Input
{{ page.tags | pop | inspect }}Output["Seattle", "Tacoma"]
- Shift (
shift) -
Remove an item from the beginning of an array
Category Array Management
- Examples
-
Input
{{ page.tags | shift | inspect }}Output["Tacoma", "Spokane"]
- Unshift (
unshift) -
Insert an item at the beginning of an array
Category Array Management
- Examples
-
Input
{{ page.tags | unshift: "Olympia" | inspect }}Output["Olympia", "Seattle", "Tacoma", "Spokane"]
- Relative URL (
relative_url) -
Prepend
baseurlconfig value to the input to convert a URL path into a relative URL. This is recommended for a site that is hosted on a subpath of a domain.Requires registration of a site.baseurlobject outsidejekyll buildcontexts.Category String Conversion
- Examples
-
Input
{{ "test-path" | relative_url }}Output/docs/test-path
- Absolute URL (
absolute_url) -
Prepend
urlandbaseurlvalues to the input to convert a URL path to an absolute URL.Requires registration of site.baseurlandsite.urlobjects outsidejekyll buildcontexts.Category String Conversion
- Examples
-
Input
{{ "test-path" | absolute_url }}Outputhttps://example.com/docs/test-path
- Markdownify (
markdownify) -
Converts a Markdown string to HTML.
Category String Conversion
- Examples
-
Input
{{ "Test with **bold** and a [link](https://example.com)." | markdownify }}Output<p>Test with <strong>bold</strong> and a <a href="https://example.com">link</a>.</p>
- Smartify (
smartify) -
Convert "quotes" into “smart quotes.”
Category String Conversion
- Examples
-
Input
{{ 'He said, "Hello!"' | smartify }}OutputHe said, “Hello!”
- Sassify (
sassify) -
Convert an indented-syntax Sass string into CSS.
Category String Conversion
- Examples
-
Input
{{ sass_text | sassify }}Outputbody { color: red; }
- Scssify (
scssify) -
Convert a SCSS-formatted (brace/semicolon syntax) string into CSS.
Category String Conversion
- Examples
-
Input
{{ scss_text | scssify }}Outputbody { color: red; }
Filters from AsciiSourcerer
- Slugify (
slugify) -
Convert a string into a lowercase URL "slug".
This is not the Jekyll version. Category String Conversion
- Examples
-
Input
{{ "The _config.yml file" | slugify }}Outputthe-config-yml-fileInput{{ "The _config.yml file" | slugify: "_" }}Outputthe_config_yml_file
- Inspect (
inspect) -
Convert an object into its String representation for debugging. Overrides Jekyll’s
inspectfilter, adding an optionalformatargument:html(default) reproduces Jekyll’s own behavior exactly (an HTML-escapedObject#inspectstring, quotes become");yamlandjsonrender the object in those formats instead.Category Object Analysis
- Examples
-
Example 1. Default (html) format, matches Jekyll’s inspectInput
{{ tags_array | inspect }}Output["foo", "bar", "baz"]Example 2. YAML formatInput{{ tags_array | inspect: "yaml" }}Output--- - foo - bar - bazExample 3. JSON formatInput{{ tags_array | inspect: "json" }}Output["foo","bar","baz"]
- Sum (
sum) -
Sums a numeric array, or an array of Hashes at the given property.
(This filter duplicates Shopify’s
sumfilter.)Category Math Operations
- Examples
-
Input
{{ data.members | sum: "grad_year" }}Output6040
- Remove Last (
remove_last) -
Removes the last instance of a substring from a string.
(This filter duplicates Shopify’s
remove_lastfilter.)Category String Conversion
- Examples
-
Input
{{ "Ground control to Major Tom." | remove_last: "o" }}OutputGround control to Major Tm.
- Replace Last (
replace_last) -
Replaces the last instance of a substring in a string with a replacement.
(This filter duplicates Shopify’s
replace_lastfilter.)Category String Conversion
- Examples
-
Input
{{ "Ground control to Major Tom." | replace_last: "o", "0" }}OutputGround control to Major T0m.
- Squish (
squish) -
Strips leading and trailing whitespace and collapses interior runs of whitespace to a single space.
(This filter duplicates Liquid 5’s
squishfilter.)Category String Conversion
- Examples
-
Input
{{ " A string that is obviously longer than 25 characters " | squish }}OutputA string that is obviously longer than 25 characters
- Wrap (
wrap) -
Category String Conversion
- Examples
-
Input
{{ "A string that is obviously longer than 25 characters" | wrap: 25 }}OutputA string that is obviously longer than 25 characters
- Comment Wrap (
commentwrap) -
Category String Conversion
- Examples
-
Input
{{ comment_text | commentwrap: 25, "// " }}Output// A string that is // obviously longer than 25 // charactersInput{{ comment_text | commentwrap: 25, "xml" }}Output<!-- A string that is obviously longer than 25 characters -->Input{{ comment_text | commentwrap: 25, "/*|*/" }}Output/* A string that is obviously longer than 25 characters */
- Convert to CLI Arguments (
to_cli_args) -
Transform a Hash into a string of CLI-formatted arguments. Accepts an optional template name to format the output. See
parameterssection for all available templates and their output formats. When no template is specified, defaults tolong_spaceformat. Arguments are joined with a space by default; can be customized via delimiter parameter.Category Object Conversion
- Examples
-
Example 4. Default (long_space) formatInput
{{ my_flat_hash | to_cli_args }}Output--key1 valuu_one --key2 val_two --key3 third valueExample 5. Long equals formatInput{{ my_flat_hash | to_cli_args: "long_equals" }}Output--key1=valuu_one --key2=val_two --key3=third valueExample 6. Single-letter flags with valuesInput{{ cli_flags_hash | to_cli_args: "short_space" }}Output-k valuu_one -v val_two -o third valueExample 7. Positional arguments onlyInput{{ my_flat_hash | to_cli_args: "positional" }}Outputvaluu_one val_two third valueExample 8. Environment variable format (uppercase keys)Input{{ my_flat_hash | to_cli_args: "env_arg" }}OutputKEY1=valuu_one KEY2=val_two KEY3=third valueExample 9. Key=value formatInput{{ my_flat_hash | to_cli_args: "keyval" }}Outputkey1=valuu_one key2=val_two key3=third value
- Data objects to YAML (
to_yaml) -
Turn any parameter or data object into YAML format.
Category Object Conversion
- Examples
-
Input
{{ my_flat_hash | to_yaml }}Output--- key1: valuu_one key2: val_two key3: third valueInput{{ my_flat_hash | to_yaml: "flow" }}Output{key1: "valuu_one", key2: "val_two", key3: "third value"}Input{{ page.tags | to_yaml }}Output--- - Seattle - Tacoma - SpokaneInput{{ page.tags | to_yaml: "flow" }}Output["Seattle", "Tacoma", "Spokane"]Input{{ page.tags | to_yaml: "flow", "quotes" }}Output["Seattle", "Tacoma", "Spokane"]
- Data objects to JSON (
to_json) -
Turn any parameter or data object into JSON format.
Category Object Conversion
- Examples
-
Input
{{ my_flat_hash | to_json }}Output{"key1":"valuu_one","key2":"val_two","key3":"third value"}Input{{ page.tags | to_json }}Output["Seattle","Tacoma","Spokane"]Input{{ odd_keys_hash | to_json }}Output{"key 1":"valuu_one","$key2":"val_two","key:3":"third value"}
- Regular Expression Replace (
replace_regex) -
Use regular expressions to match and replace text patterns.
Category String Management
- Examples
-
Input
{{ "hello world" | replace_regex: "world", "there" }}Outputhello thereInput{{ "one,two,three" | replace_regex: ",", "-" }}Outputone-two-three
- Pattern Match (
match) -
Returns of string or number matches pattern.
Category String Analysis
- Examples
-
Input
{% assign matched = "testword" | match: "^.*word$" %} {% if matched %}It matched!{% endif %}OutputIt matched!
- Holds Liquid (
holds_liquid) -
Returns true if a snippet of text contains Liquid markup tags.
Category Object Analysis
- Examples
-
Input
{{ liquidy_text | holds_liquid }}OutputtrueInput{{ "This is just text." | holds_liquid }}Outputfalse
- Metastore list concat (
store_list_concat) -
Concatenates each Array-formatted value of the same-named property across all nodes in an Array of Hashes (Metastore). Accepts an Array of Hashes and the keyname of a property to collect from.
Category Array Management
- Examples
-
Input
{{ data.metastore | store_list_concat: "children" | jsonify }}Output["child1","child2","child3","child4","child5","child6"]
- Metastore list duplicates (
store_list_dupes) -
Returns a list of duplicate items among multiple Arrays across multiple same-named properties in an Array of Hashes (Metastore). Accepts an Array of Hashes and the keyname of a Scalar property to check; returns the names of duplicate properties.
Category Array Management
- Examples
-
Input
{{ data.metastore | store_list_dupes: "children" | jsonify }}Output["child1"]
Filters from Shopify
- Absolute Value (
abs) -
Returns the absolute value of a number.
Category Math Operations
- Examples
-
Input
{{ -17 | abs }}Output17Input{{ "-19.86" | abs }}Output19.86
- Append (
append) -
Adds the specified string to the end of another string.
Category String Management
- Examples
-
Input
{{ "/my/fancy/url" | append: ".html" }}Output/my/fancy/url.html
- At Least (
at_least) -
Limits a number to a minimum value; returns the input unchanged if it’s already at or above the minimum.
Category Math Operations
- Examples
-
Input
{{ 4 | at_least: 5 }}Output5Input{{ 4 | at_least: 3 }}Output4
- At Most (
at_most) -
Limits a number to a maximum value; returns the input unchanged if it’s already at or below the maximum.
Category Math Operations
- Examples
-
Input
{{ 4 | at_most: 5 }}Output4Input{{ 4 | at_most: 3 }}Output3
- Capitalize (
capitalize) -
Capitalizes the first character of a string and downcases the rest. Only the first character is affected, so later words are not capitalized.
Category String Conversion
- Examples
-
Input
{{ "my GREAT title" | capitalize }}OutputMy great title
- Ceiling (
ceil) -
Rounds a number up to the nearest whole number. Liquid tries to convert the input to a number before applying the filter.
Category Math Operations
- Examples
-
Input
{{ 1.2 | ceil }}Output2
- Compact (
compact) -
Removes any
nilvalues from an array.Category Array Management
- Examples
-
Input
{% assign compacted = mixed_array | compact %} {{ compacted | join: "," }}Outputa,b,c
- Concatenate (
concat) -
Concatenates (joins together) multiple arrays. The resulting array contains all the items from the input arrays.
Category Array Management
- Examples
-
Input
{% assign fruits = "apples, oranges" | split: ", " %} {% assign veggies = "carrots, turnips" | split: ", " %} {{ fruits | concat: veggies | join: "," }}Outputapples,oranges,carrots,turnips
- Date Format (
date) -
Converts a timestamp into another date format, using the same format syntax as
strftime.Category Date Formatting
- Examples
-
Input
{{ data.time | date: "%Y-%m-%d" }}Output2008-11-07
- Default (
default) -
Sets a fallback value for a variable that is
nil,false, or empty. Has no effect if the input already has a value.Category Variable Defaults
- Examples
-
Input
{{ nonexistent_var | default: "fallback" }}Outputfallback
- Divided By (
divided_by) -
Divides a number by another number. The result’s type matches the divisor’s: dividing by an integer floors to an integer, dividing by a float returns a float.
Category Math Operations
- Examples
-
Input
{{ 16 | divided_by: 4 }}Output4Input{{ 20 | divided_by: 7 }}Output2Input{{ 20 | divided_by: 7.0 }}Output2.857142857142857
- Downcase (
downcase) -
Makes each character in a string lowercase.
Category String Conversion
- Examples
-
Input
{{ "Parker Moore" | downcase }}Outputparker moore
- Escape (
escape) -
Escapes a string’s HTML-unsafe characters (so it can safely be embedded in HTML markup).
Category String Conversion
- Examples
-
Input
{{ "Have you read 'James & the Giant Peach'?" | escape }}OutputHave you read 'James & the Giant Peach'?
- Escape Once (
escape_once) -
Escapes a string’s HTML-unsafe characters without double-escaping entities that are already escaped.
Category String Conversion
- Examples
-
Input
{{ "1 < 2 & 3" | escape_once }}Output1 < 2 & 3Input{{ "1 < 2 & 3" | escape_once }}Output1 < 2 & 3
- First (
first) -
Returns the first item of an array.
Category Array Selection
- Examples
-
Input
{{ "Ground control to Major Tom." | split: " " | first }}OutputGround
- Floor (
floor) -
Rounds a number down to the nearest whole number. Liquid tries to convert the input to a number before applying the filter.
Category Math Operations
- Examples
-
Input
{{ 1.2 | floor }}Output1
- Join (
join) -
Combines the items in an array into a single string, using the argument as a separator.
Category Object Conversion
- Examples
-
Input
{% assign beatles = "John, Paul, George, Ringo" | split: ", " %} {{ beatles | join: " and " }}OutputJohn and Paul and George and Ringo
- Last (
last) -
Returns the last item of an array.
Category Array Selection
- Examples
-
Input
{{ "Ground control to Major Tom." | split: " " | last }}OutputTom.
- Left Strip (
lstrip) -
Removes whitespace (tabs, spaces, newlines) from the left side of a string. Does not affect spaces between words.
Category String Management
- Examples
-
Input
{{ " So much room " | lstrip }}!OutputSo much room !
- Map (
map) -
Creates an array of values by extracting the values of a named property from an array of objects.
Category Object Conversion
- Examples
-
Input
{{ data.members | map: "user" | join: "," }}Outputandie,lonnie,cindy
- Minus (subtract) (
minus) -
Subtracts a number from another number.
Category Math Operations
- Examples
-
Input
{{ 4 | minus: 2 }}Output2Input{{ 16 | minus: 4 }}Output12
- Modulo (
modulo) -
Returns the remainder of a division operation.
Category Math Operations
- Examples
-
Input
{{ 3 | modulo: 2 }}Output1Input{{ 24 | modulo: 7 }}Output3
- Newline to Break Tag (
newline_to_br) -
Inserts an HTML line break (
<br />) in front of each newline in a string.Category String Conversion
- Examples
-
Input
{% capture s %}Hello there{% endcapture %}{{ s | newline_to_br }}OutputHello<br /> there
- Plus (add) (
plus) -
Adds a number to another number.
Category Math Operations
- Examples
-
Input
{{ 4 | plus: 2 }}Output6
- Prepend (
prepend) -
Adds the specified string to the beginning of another string.
Category String Management
- Examples
-
Input
{{ "apples, oranges, and bananas" | prepend: "Some fruit: " }}OutputSome fruit: apples, oranges, and bananas
- Remove (
remove) -
Removes every occurrence of the specified substring from a string.
Category String Conversion
- Examples
-
Input
{{ "I strained to see the train through the rain" | remove: "rain" }}OutputI sted to see the t through the
- Remove First (
remove_first) -
Removes only the first occurrence of the specified substring from a string.
Category String Conversion
- Examples
-
Input
{{ "I strained to see the train through the rain" | remove_first: "rain" }}OutputI sted to see the train through the rain
- Replace (
replace) -
Replaces every occurrence of the first argument in a string with the second argument.
Category String Conversion
- Examples
-
Input
{{ "Take my protein pills and put my helmet on" | replace: "my", "your" }}OutputTake your protein pills and put your helmet on
- Replace First (
replace_first) -
Replaces only the first occurrence of the first argument in a string with the second argument.
Category String Conversion
- Examples
-
Input
{{ "Take my protein pills and put my helmet on" | replace_first: "my", "your" }}OutputTake your protein pills and put my helmet on
- Reverse (
reverse) -
Reverses the order of the items in an array. Cannot reverse a string directly; split it into an array first.
Category Array Organizing
- Examples
-
Input
{% assign arr = "apples, oranges, peaches, plums" | split: ", " %} {{ arr | reverse | join: ", " }}Outputplums, peaches, oranges, apples
- Round (
round) -
Rounds a number to the nearest integer, or to a given number of decimal places if an argument is passed.
Category Math Operations
- Examples
-
Input
{{ 1.2 | round }}Output1Input{{ 2.7 | round }}Output3Input{{ 183.357 | round: 2 }}Output183.36
- Right Strip (
rstrip) -
Removes whitespace (tabs, spaces, newlines) from the right side of a string. Does not affect spaces between words.
Category String Conversion
- Examples
-
Input
{{ " So much room " | rstrip }}!OutputSo much room!
- Size (
size) -
Returns the number of characters in a string, or the number of items in an array.
Category Object Analysis
- Examples
-
Input
{{ "Ground control to Major Tom." | size }}Output28
- Slice (
slice) -
Returns a substring or array slice, starting at the index given by the first argument. An optional second argument gives the length. Negative indices count from the end.
Category Object Conversion
- Examples
-
Input
{{ "Liquid" | slice: 0 }}OutputLInput{{ "Liquid" | slice: 2, 3 }}OutputquiInput{{ "Liquid" | slice: -3, 2 }}Outputui
- Split (
split) -
Divides a string into an array using the argument as a separator. Commonly used to convert delimited text into an array.
Category Object Conversion
- Examples
-
Input
{% assign beatles = "John, Paul, George, Ringo" | split: ", " %} {{ beatles | join: "|" }}OutputJohn|Paul|George|Ringo
- Strip (
strip) -
Removes whitespace (tabs, spaces, newlines) from both sides of a string. Does not affect spaces between words.
Category String Conversion
- Examples
-
Input
{{ " So much room " | strip }}!OutputSo much room!
- Strip HTML (
strip_html) -
Removes any HTML tags from a string.
Category String Conversion
- Examples
-
Input
{{ "Have <em>you</em> read <strong>Ulysses</strong>?" | strip_html }}OutputHave you read Ulysses?
- Strip Newlines (
strip_newlines) -
Removes any newline characters from a string.
Category String Conversion
- Examples
-
Input
{% capture s %}Hello there{% endcapture %}{{ s | strip_newlines }}OutputHellothere
- Times (multiply) (
times) -
Multiplies a number by another number.
Category Math Operations
- Examples
-
Input
{{ 3 | times: 2 }}Output6
- Truncate (
truncate) -
Shortens a string to the given number of characters. If shortened, an ellipsis (
…) is appended and counts against the total; pass a second argument to use a different (or no) ellipsis.Category String Management
- Examples
-
Input
{{ "Ground control to Major Tom." | truncate: 20 }}OutputGround control to...Input{{ "Ground control to Major Tom." | truncate: 25, ", and so on" }}OutputGround control, and so on
- Truncate Words (
truncatewords) -
Shortens a string to the given number of words. If shortened, an ellipsis (
…) is appended; pass a second argument to use a different (or no) ellipsis.Category String Conversion
- Examples
-
Input
{{ "Ground control to Major Tom." | truncatewords: 3 }}OutputGround control to...
- Uniq (
uniq) -
Removes any duplicate items from an array, preserving the first occurrence’s order.
Category Array Management
- Examples
-
Input
{% assign arr = "ants, bugs, bees, bugs, ants" | split: ", " %} {{ arr | uniq | join: "," }}Outputants,bugs,bees
- Upcase (
upcase) -
Makes each character in a string uppercase.
Category String Conversion
- Examples
-
Input
{{ "Parker Moore" | upcase }}OutputPARKER MOORE
- URL Decode (
url_decode) -
Decodes a string that has been encoded as a URL, or by
url_encode.Category String Recode
- Examples
-
Input
{{ "%27Stop%21%27+said+Fred" | url_decode }}Output'Stop!' said Fred
- URL Encode (
url_encode) -
Converts any URL-unsafe characters in a string into percent-encoded characters. A space becomes a
+rather than a percent-encoded character.Category String Recode
- Examples
-
Input
{{ "john@liquid.com" | url_encode }}Outputjohn%40liquid.comInput{{ "Tetsuro Takara" | url_encode }}OutputTetsuro+Takara
Filters from schemagraphy
- SGYML Type (
sgyml_type) -
Category data-type
Filters from jekyll-asciidoc
- AsciiDocify (
asciidocify) -
Convert an AsciiDoc string to HTML, with or without paragraphing.
Category String Conversion
- Examples
-
Input
{{ "Test with *bold* and a http://example.com[link]." | asciidocify }}Output<div class="paragraph"> <p>Test with <strong>bold</strong> and a <a href="http://example.com">link</a>.</p> </div>Input{{ "Test with *bold* and a http://example.com[link]." | asciidocify: "inline" }}OutputTest with <strong>bold</strong> and a <a href="http://example.com">link</a>.