Skip to content

Commit

Permalink
add a failing test for the markup feature inside liquid
Browse files Browse the repository at this point in the history
  • Loading branch information
JaKXz committed May 28, 2021
1 parent 3579553 commit 208830e
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 2 deletions.
2 changes: 1 addition & 1 deletion components/prism-liquid.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Prism.languages.liquid = {
pattern: /(^|[\s;|&])(?:append|prepend|capitalize|cycle|cols|increment|decrement|abs|at_least|at_most|ceil|compact|concat|date|default|divided_by|downcase|escape|escape_once|first|floor|join|last|lstrip|map|minus|modulo|newline_to_br|plus|remove|remove_first|replace|replace_first|reverse|round|rstrip|size|slice|sort|sort_natural|split|strip|strip_html|strip_newlines|times|truncate|truncatewords|uniq|upcase|url_decode|url_encode|include|paginate)(?=$|[\s;|&])/,
lookbehind: true
},
'other': {
'markup': {
// We want non-blank matches
pattern: /\S(?:[\s\S]*\S)?/,
inside: Prism.languages.markup
Expand Down
2 changes: 1 addition & 1 deletion components/prism-liquid.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

29 changes: 29 additions & 0 deletions tests/languages/markup+liquid/markup_feature.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<div>
<span>

----------------------------------------------------

[
["markup", [
["tag", [
["tag", [
["punctuation", "<"],
"div"
]],
["punctuation", ">"]
]]
]],
["markup", [
["tag", [
["tag", [
["punctuation", "<"],
"span"
]],
["punctuation", ">"]
]]
]]
]

----------------------------------------------------

Checks for Markup inside Liquid.

0 comments on commit 208830e

Please sign in to comment.