Mercurial
comparison .cms/lib/codemirror/mode/toml/index.html @ 0:78edf6b517a0 draft
24.10
author | Coffee CMS <info@coffee-cms.ru> |
---|---|
date | Fri, 11 Oct 2024 22:40:23 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:78edf6b517a0 |
---|---|
1 <!doctype html> | |
2 | |
3 <title>CodeMirror: TOML Mode</title> | |
4 <meta charset="utf-8"/> | |
5 <link rel=stylesheet href="../../doc/docs.css"> | |
6 | |
7 <link rel="stylesheet" href="../../lib/codemirror.css"> | |
8 <script src="../../lib/codemirror.js"></script> | |
9 <script src="toml.js"></script> | |
10 <style>.CodeMirror {border-top: 1px solid black; border-bottom: 1px solid black;}</style> | |
11 <div id=nav> | |
12 <a href="https://codemirror.net/5"><h1>CodeMirror</h1><img id=logo src="../../doc/logo.png" alt=""></a> | |
13 | |
14 <ul> | |
15 <li><a href="../../index.html">Home</a> | |
16 <li><a href="../../doc/manual.html">Manual</a> | |
17 <li><a href="https://github.com/codemirror/codemirror5">Code</a> | |
18 </ul> | |
19 <ul> | |
20 <li><a href="../index.html">Language modes</a> | |
21 <li><a class=active href="#">TOML Mode</a> | |
22 </ul> | |
23 </div> | |
24 | |
25 <article> | |
26 <h2>TOML Mode</h2> | |
27 <form><textarea id="code" name="code"> | |
28 # This is a TOML document. Boom. | |
29 | |
30 title = "TOML Example" | |
31 | |
32 [owner] | |
33 name = "Tom Preston-Werner" | |
34 organization = "GitHub" | |
35 bio = "GitHub Cofounder & CEO\nLikes tater tots and beer." | |
36 dob = 1979-05-27T07:32:00Z # First class dates? Why not? | |
37 | |
38 [database] | |
39 server = "192.168.1.1" | |
40 ports = [ 8001, 8001, 8002 ] | |
41 connection_max = 5000 | |
42 enabled = true | |
43 | |
44 [servers] | |
45 | |
46 # You can indent as you please. Tabs or spaces. TOML don't care. | |
47 [servers.alpha] | |
48 ip = "10.0.0.1" | |
49 dc = "eqdc10" | |
50 | |
51 [servers.beta] | |
52 ip = "10.0.0.2" | |
53 dc = "eqdc10" | |
54 | |
55 [clients] | |
56 data = [ ["gamma", "delta"], [1, 2] ] | |
57 | |
58 # Line breaks are OK when inside arrays | |
59 hosts = [ | |
60 "alpha", | |
61 "omega" | |
62 ] | |
63 </textarea></form> | |
64 <script> | |
65 var editor = CodeMirror.fromTextArea(document.getElementById("code"), { | |
66 mode: {name: "toml"}, | |
67 lineNumbers: true | |
68 }); | |
69 </script> | |
70 <h3>The TOML Mode</h3> | |
71 <p> Created by Forbes Lindesay.</p> | |
72 <p><strong>MIME type defined:</strong> <code>text/x-toml</code>.</p> | |
73 </article> |