-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.html
48 lines (42 loc) · 1.52 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<!doctype html>
<title>CodeMirror: Liquid mode</title>
<meta charset="utf-8"/>
<link rel=stylesheet href="../CodeMirror/doc/docs.css">
<link rel="stylesheet" href="../CodeMirror/lib/codemirror.css">
<script src="../CodeMirror/lib/codemirror.js"></script>
<script src="../CodeMirror/addon/edit/matchbrackets.js"></script>
<script src="../CodeMirror/mode/xml/xml.js"></script>
<script src="liquid.js"></script>
<style>.CodeMirror {border-top: 1px solid black; border-bottom: 1px solid black;}</style>
<div id=nav>
<a href="https://codemirror.net"><h1>CodeMirror</h1><img id=logo src="../CodeMirror/doc/logo.png"></a>
<ul>
<li><a href="../CodeMirror/index.html">Home</a>
<li><a href="../CodeMirror/doc/manual.html">Manual</a>
<li><a href="https://github.com/codemirror/codemirror">Code</a>
</ul>
<ul>
<li><a href="../index.html">Language modes</a>
<li><a class=active href="#">Liquid</a>
</ul>
</div>
<article>
<h2>Liquid mode</h2>
<form><textarea id="code" name="code">
{% if user %}
{% comment %} Greets the user. {% endcomment %}
Hello <b>{{ user.name }}</b>!
{% endif %}
</textarea></form>
<script>
var editor = CodeMirror.fromTextArea(document.getElementById("code"), {
lineNumbers: true,
matchBrackets: true,
mode: "text/x-liquid",
indentUnit: 2,
indentWithTabs: false
});
</script>
<p>A mode for <a href="https://shopify.github.io/liquid/">Liquid</a>.</p>
<p><strong>MIME type defined:</strong> <code>text/x-liquid</code>.</p>
</article>