-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathexample.semper
47 lines (47 loc) · 1.28 KB
/
example.semper
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
!!!
html
head
title #{laugh}
body
// this is a comment
bar = 'sur'+'vive'
h1#hdr(background="foo(1) "hah!"")
| Bar #{"'These quotes should \"" + bar + '"\', he said'} hopefully
//
multiline
comment
#survivor= bar
This text included after the above is noisily evalled & is escaped
p.fred.fly
+person
| This is some text which
| shows a multi-line example
| and interpolates the name of #{given_name}
| #{family_name}
p.multi.line.mode
|
This is some more text <which>
illustrates indented multi-line
mode
subst = 'substituted'
p.another.multi.line.mode.
Text inserted and not evaluated but is #{subst}
MyFunkyHeader = 'A list-item header'
ul: li#foo(a="b"): h4= MyFunkyHeader
li#bar: h4 Second header
+person
li= given_name + ' ' + family_name
+home_address
p.alternate.multi.line.mode
|
Home address is at: #{street} {in the suburb}: #{suburb}
.foo#xid divtext
#survivor2!= "<unescaped tag>"
#survivor3!=
"<This will be ignored; evaluated code must be inline>"
#hiddencode- var x = 2*3;
This text included after the above is silently evalled
//-
This is a multi-line
comment for the source only,
and won't be output