index.html 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <!doctype html>
  2. <title>CodeMirror: Jade Templating Mode</title>
  3. <meta charset="utf-8"/>
  4. <link rel=stylesheet href="../../doc/docs.css">
  5. <link rel="stylesheet" href="../../lib/codemirror.css">
  6. <script src="../../lib/codemirror.js"></script>
  7. <script src="jade.js"></script>
  8. <style type="text/css">.CodeMirror {border-top: 1px solid black; border-bottom: 1px solid black;}</style>
  9. <div id=nav>
  10. <a href="http://codemirror.net"><img id=logo src="../../doc/logo.png"></a>
  11. <ul>
  12. <li><a href="../../index.html">Home</a>
  13. <li><a href="../../doc/manual.html">Manual</a>
  14. <li><a href="https://github.com/marijnh/codemirror">Code</a>
  15. </ul>
  16. <ul>
  17. <li><a href="../index.html">Language modes</a>
  18. <li><a class=active href="#">Jade Templating Mode</a>
  19. </ul>
  20. </div>
  21. <article>
  22. <h2>Jade Templating Mode</h2>
  23. <form><textarea id="code" name="code">
  24. doctype 5
  25. html
  26. head
  27. title= "Jade Templating CodeMirror Mode Example"
  28. link(rel='stylesheet', href='/css/bootstrap.min.css')
  29. link(rel='stylesheet', href='/css/index.css')
  30. script(type='text/javascript', src='/js/jquery-1.9.1.min.js')
  31. script(type='text/javascript', src='/js/bootstrap.min.js')
  32. body
  33. div.header
  34. h1 Welcome to this Example
  35. div.spots
  36. if locals.spots
  37. each spot in spots
  38. div.spot.well
  39. div
  40. if spot.logo
  41. img.img-rounded.logo(src=spot.logo)
  42. else
  43. img.img-rounded.logo(src="img/placeholder.png")
  44. h3
  45. a(href=spot.hash) ##{spot.hash}
  46. if spot.title
  47. span.title #{spot.title}
  48. if spot.desc
  49. div #{spot.desc}
  50. else
  51. h3 There are no spots currently available.
  52. </textarea></form>
  53. <script>
  54. var editor = CodeMirror.fromTextArea(document.getElementById("code"), {
  55. mode: {name: "jade", alignCDATA: true},
  56. lineNumbers: true
  57. });
  58. </script>
  59. <h3>The Jade Templating Mode</h3>
  60. <p> Created by Drew Bratcher. Managed as part of an Adobe Brackets extension at <a href="https://github.com/dbratcher/brackets-jade">https://github.com/dbratcher/brackets-jade</a>.</p>
  61. <p><strong>MIME type defined:</strong> <code>text/x-jade</code>.</p>
  62. </article>