This repository has been archived by the owner on Apr 25, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.emr
130 lines (110 loc) · 2.84 KB
/
index.emr
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
* ->
Emerald Language Website
Copyright 2016, Emerald
html
head
title Emerald language
styles
"css/emerald.css"
"css/syntax.css"
scripts
"https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"
"js/parser.js"
* NOTE: add metas rule.
meta (
name "viewport"
content "width=device-width"
)
body
header
h1 Emerald
p A language agnostic templating engine
section (
class "split"
)
section
h2
span sample.emr (
class "code"
)
pre (
id "main-code"
)
code =>
html
head
title Emerald Example
styles
"css/main.css"
"css/footer.css"
scripts
"js/main.js"
body
header
h1 Emerald Language
h3 The people
main
each people as person
section
h2 |person.name|
p |person.info|
footer
p Copyright 2016, Emerald Language
h2.code
span context.json (
class "code"
)
pre
code =>
{
people: [
{name: "Andrew", info: "Plays the sax."},
{name: "Dave", info: "Draws cool stuff."}
{name: "Yu Chen Hou"}
]
}
section
h2
span sample.html (
class "code"
)
pre (
style "flex: 1"
)
code ->
<html>
<head>
<title>Emerald Example</title>
<link rel="stylesheet" href="css/main.css" />
<link rel="stylesheet" href="css/footer.css" />
<script type="text/javascript" src="js/main.js"></script>
</head>
<body>
<header>
<h1>Emerald Language</h1>
<h3>The people</h3>
</header>
<main>
<section>
<h2>Andrew</h2>
<p>Plays the sax.</p>
</section>
<section>
<h2>Dave</h2>
<p>Draws cool stuff.</p>
</section>
<section>
<h2>Yu Chen Hou</h2>
</section>
</main>
<footer>
<p>Copyright 2016, Emerald Language</p>
</footer>
</body>
</html>
footer
a View on GitHub (
class "button"
href "https://github.com/emerald-lang/emerald"
target "_blank"
)