You can put whatever you want in the script tag if you give it a โtypeโ that the browser does not understand as โJavaScriptโ:
<script id='Turtle' type='text/poem'> Turtle, turtle, on the ground; Pink and shiny - turn around. </script>
You can get the content through the "innerHTML" property:
var poemScript = document.getElementById('Turtle'); var poem = poemScript.innerHTML;
Here is jsfiddle shown.
This trick has been popular lately with people doing page creation on the client side using templates.
source share