Created
November 30, 2012 15:36
-
-
Save davidl/4176483 to your computer and use it in GitHub Desktop.
Demo for Prism.js pull request 61 re: empty CDATA sections
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Demo for Prism.js pull request 61 re: empty CDATA sections */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Demo for Prism.js pull request 61 re: empty CDATA sections --> | |
<!-- https://github.com/LeaVerou/prism/pull/61 --> | |
<demo> | |
<hello>This is a demo of XML-style markup with some CDATA sections (empty and non-empty) for <a href="https://github.com/LeaVerou/prism/pull/61">Prism pull request 61</a>. Note how Prism (in the "HTML & Result" panel) highlights the markup:</hello> | |
<demo-content status="wraps-correctly"> | |
<text>A non-empty CDATA section works great!</text> | |
<data><![CDATA[<p>Not empty</p>]]></data> | |
</demo-content> | |
<demo-content status="wraps-correctly"> | |
<text>A non-empty CDATA section works great:</text> | |
<data><![CDATA[<p>Not empty</p>]]></data> | |
<text>Another non-empty CDATA section also works great:</text> | |
<data><![CDATA[<p>Not empty</p>]]></data> | |
</demo-content> | |
<demo-content status="wraps-incorrectly"> | |
<text>An empty CDATA section:</text> | |
<data><![CDATA[]]></data> | |
<text>Another empty CDATA section:</text> | |
<data><![CDATA[]]></data> | |
</demo-content> | |
<demo-content status="wraps-incorrectly"> | |
<text>An empty CDATA section causes Prism to insert an element wrapping the CDATA tag and all content up to the "]]>" text in the second "text" node.</text> | |
<data><![CDATA[]]></data> | |
<text>]]></text> | |
</demo-content> | |
</demo> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"view":"split","fontsize":"100","seethrough":"","prefixfree":"","page":"html"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment