-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.jade.go
61 lines (47 loc) · 1.29 KB
/
index.jade.go
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
// Code generated by "jade.go"; DO NOT EDIT.
package main
import (
"io"
"github.com/Joker/hpp"
)
const (
index__0 = `<!DOCTYPE html><html lang="en"><head><title>`
index__1 = `</title><script type="text/javascript"> if(question){
answer(40 + 2)
}</script></head><body><h1>Jade - template engine`
index__2 = `</h1><div id="container" class="col">`
index__3 = `<p> Jade/Pug is a terse and simple
templating language with
a <strong>focus</strong> on performance
and powerful features.</p></div><footer><div class="footer">2019</div></footer></body></html>`
index__4 = `<div id="cmd">Precompile jade templates to `
index__5 = ` code.</div>`
index__6 = `<p>You are amazing</p>`
index__7 = `<p>Get on it!</p>`
)
func Index(pageTitle string, youAreUsingJade bool, wr io.Writer) {
r, w := io.Pipe()
go func() {
buffer := &WriterAsBuffer{w}
buffer.WriteString(index__0)
WriteEscString(pageTitle, buffer)
buffer.WriteString(index__1)
{
var (
golang = "Go"
)
buffer.WriteString(index__4)
WriteEscString(golang, buffer)
buffer.WriteString(index__5)
}
buffer.WriteString(index__2)
if youAreUsingJade {
buffer.WriteString(index__6)
} else {
buffer.WriteString(index__7)
}
buffer.WriteString(index__3)
w.Close()
}()
hpp.Format(r, wr)
}