-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdss.config.js
45 lines (42 loc) · 1.25 KB
/
dss.config.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
module.exports = {
templatePath: 'src/dss',
outputPath: 'dist',
parsers: {
link: function(i, line, block){
var exp = new RegExp('(b(https?|ftp|file)://[-A-Z0-9+&@#/%?=~_|!:,.;]*[-A-Z0-9+&@#/%=~_|])', 'ig');
line.replace(exp, '<a href="$1">$1</a>');
return line;
},
lvar: function(i, line, block) {
var lvar = line.split(' - ');
return {
name: lvar[0] ? lvar[0] : '',
defaults: lvar[1] ? lvar[1] : '',
description: lvar[2] ? lvar[2] : ''
};
},
see: function(i, line, block) {
return line;
},
depends: function(i, line, block) {
return {
depends: line
};
},
requires: function(i, line, block) {
return {
requires: line
};
},
method: function(i, line, block) {
var method = line.split(' - ');
return {
name: method[0] ? method[0] : '',
description: method[1] ? method[1] : ''
};
},
component: function(i, line,block) {
return line;
}
}
};