-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocs.js
More file actions
79 lines (75 loc) · 1.76 KB
/
Copy pathdocs.js
File metadata and controls
79 lines (75 loc) · 1.76 KB
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
const Docma = require('docma');
const pkg = require('../package.json');
const base = '/node-cocoadialog';
Docma.create()
.build({
src: [
'./Core/**/*.js', './Dialog/**/*.js',
{
guide: './README.md',
examples: './Examples/README.md',
msgbox: './Examples/MsgBox.md',
progressbar: './Examples/ProgressBar.md'
}
],
dest: './docs',
app: {
base: base,
title: `${pkg.name} (node.js)`,
routing: 'query',
entrance: 'content:guide'
},
jsdoc: {
hierarchy: true,
sort: 'grouped',
package: true
},
template: {
path: 'default',
options: {
title: `${pkg.name} (node.js)`,
sidebar: true,
collapsed: false,
outline: 'tree',
badges: true,
search: true,
symbolMeta: true,
navbar: true,
navItems: [
{
label: 'Getting Started',
href: base,
iconClass: 'ico-target4'
},
{
label: 'API',
href: `${base}/?api`,
iconClass: 'ico-book'
},
{
label: 'Examples',
href: `${base}/?content=examples`,
iconClass: 'ico-mouse-pointer'
},
{
label: 'Releases',
iconClass: 'ico-md ico-download',
target: '_blank',
href: `${pkg.homepage}/releases`,
},
{
label: 'GitHub',
href: pkg.homepage,
target: '_blank',
iconClass: 'ico-md ico-github'
}
]
}
},
})
.then(function (success) {
console.log('Documentation is built successfully.');
})
.catch(function (error) {
console.log(error.message);
});