forked from varia/varia.website
many many many Varia's websites, work in progress: https://many.vvvvvvaria.org
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
667 B
28 lines
667 B
7 years ago
|
"""
|
||
|
Literal Tag
|
||
|
-----------
|
||
|
This implements a tag that allows explicitly showing commands which would
|
||
|
otherwise be interpreted as a liquid tag.
|
||
|
|
||
|
For example, the line
|
||
|
|
||
|
{% literal video arg1 arg2 %}
|
||
|
|
||
|
would result in the following line:
|
||
|
|
||
|
{% video arg1 arg2 %}
|
||
|
|
||
|
This is useful when the resulting line would be interpreted as another
|
||
|
liquid-style tag.
|
||
|
"""
|
||
|
from .mdx_liquid_tags import LiquidTags
|
||
|
|
||
|
@LiquidTags.register('literal')
|
||
|
def literal(preprocessor, tag, markup):
|
||
|
return '{%% %s %%}' % markup
|
||
|
|
||
|
#----------------------------------------------------------------------
|
||
|
# This import allows image tag to be a Pelican plugin
|
||
|
from liquid_tags import register
|
||
|
|