-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.js
78 lines (74 loc) · 2.16 KB
/
main.js
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
const content = {
images: [
{
text: 'PHP',
link: '/php',
source: 'https://rawgit.com/banianhost/docker-php/master/README.md'
},
// {
// text: 'Node',
// link: '/node',
// source: 'https://rawgit.com/banianhost/docker-node/master/README.md'
// },
// {
// text: 'Node Headless Chrome',
// link: '/php',
// source: 'https://rawgit.com/banianhost/node-headless-chrome/master/README.md'
// },
{
text: 'Cache Mirror',
link: '/cache-mirror',
source: 'https://rawgit.com/banianhost/docker-cache-mirror/master/README.md'
},
{
text: 'Nginx Extras',
link: '/nginx-extras',
source: 'https://rawgit.com/banianhost/docker-nginx-extras/master/README.md'
},
{
text: 'Remux',
link: '/remux',
source: 'https://rawgit.com/banianhost/docker-remux/master/README.md'
},
{
text: 'Nginx HLS',
link: '/nginx-hls',
source: 'https://rawgit.com/banianhost/docker-nginx-hls/master/README.md'
},
{
text: 'Local DNS',
link: '/localdns',
source: 'https://rawgit.com/banianhost/docker-localdns/master/README.md'
},
],
tools: [
{
text: 'µCI',
link: '/uci',
source: 'https://rawgit.com/banianhost/uci/master/README.md'
},
]
}
// -----------------------------------------------------------------------------
const allContent = Array.prototype.concat.apply([], Object.values(content))
const doc = new Docute.default({
routerMode: 'history',
getSource: function (route) {
const m = allContent.find(r => r.link === route.path)
return m ? m.source : undefined
},
nav: [
{ text: 'Images', link: '/' },
],
sidebar: [
{
text: 'Docker Images',
children: content.images
},
{
text: 'Tools',
children: content.tools
}
]
})
doc.start()