Skip to content

Incorrect display of raw / endraw tags as part of the codeAndOutput.md boilerplate #2119

Description

@lhw-1

Please confirm that you have searched existing issues in the repo

Yes, I have searched the existing issues

Any related issues?

#2118, #2120

Tell us about your environment

Ubuntu 20.04

MarkBind version

4.0.2

What did you do? Describe the bug

This issue was initially brought up in PR #2118.

While trying to add the following snippet using the codeAndOutput.md boilerplate to the documentation for raw / endraw tags, the following unexpected output occurred.

Code:

<include src="codeAndOutput.md" boilerplate >
<variable name="highlightStyle">markdown</variable>
<variable name="code" id="list-example">
{{ '{% raw %}' }} content {{ '{% endraw %}' }}
</variable>
</include>

Output:

Screenshot from 2023-01-30 17-27-50

The {% raw %} should not show up as part of the output.
The {% endraw %} should show up as part of the output.

Including raw / endraw tags to enable the rendering of the tags inside the variable to be bypassed like this:

{% raw %}

<include src="codeAndOutput.md" boilerplate >
<variable name="highlightStyle">markdown</variable>
<variable name="code" id="list-example">
{% raw %} content {% endraw %}
</variable>
</include>

{% endraw %}

This produces the exact same result as above.

Steps to reproduce

Include the above code snippet (ensure that the codeAndOutput.md boilerplate is also included) into a pre-existing MarkBind site, and observe the displayed result.

Expected behavior

The output section should display {% raw %} content {% endraw %}.

Actual behavior

The {% endraw %} did not show up as part of the output.

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions