Skip to content

Commit d432d63

Browse files
Updated dependencies, adjustments for Handlebars v3
1 parent 15df42d commit d432d63

File tree

4 files changed

+12
-8
lines changed

4 files changed

+12
-8
lines changed

bin/typedoc.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6296,7 +6296,9 @@ var td;
62966296
return null;
62976297
}
62986298
}
6299-
this.templates[fileName] = td.Handlebars.compile(Renderer.readFile(path));
6299+
this.templates[fileName] = td.Handlebars.compile(Renderer.readFile(path), {
6300+
preventIndent: true
6301+
});
63006302
}
63016303
return this.templates[fileName];
63026304
};
@@ -7536,7 +7538,7 @@ var td;
75367538
}
75377539
if (lineState == 0 /* Default */) {
75387540
lineDepth = Math.min(lineDepth, stack.length);
7539-
line = line.replace(/^\s+/, '');
7541+
line = line.replace(/^\s+/, '').replace(/\s+$/, '');
75407542
if (lineDepth > minLineDepth) {
75417543
line = Array(lineDepth - minLineDepth + 1).join('\t') + line;
75427544
}

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,12 @@
3030
"dependencies": {
3131
"typescript": "1.4.x",
3232
"typedoc-default-themes": "^0.2.5",
33-
"fs-extra": "^0.16.4",
34-
"minimatch": "^2.0.1",
35-
"handlebars": "2.0.0-alpha.4",
33+
"fs-extra": "^0.16.5",
34+
"minimatch": "^2.0.4",
35+
"handlebars": "3.0.0",
3636
"marked": "^0.3.3",
3737
"highlight.js": "^8.4.0",
38-
"shelljs": "^0.3.0",
38+
"shelljs": "^0.4.0",
3939
"progress": "^1.1.8"
4040
},
4141
"devDependencies": {

src/td/output/Renderer.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,9 @@ module td.output
142142
}
143143
}
144144

145-
this.templates[fileName] = Handlebars.compile(Renderer.readFile(path));
145+
this.templates[fileName] = Handlebars.compile(Renderer.readFile(path), {
146+
preventIndent: true
147+
});
146148
}
147149

148150
return this.templates[fileName];

src/td/output/plugins/PrettyPrintPlugin.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ module td.output
142142

143143
if (lineState == PrettyPrintState.Default) {
144144
lineDepth = Math.min(lineDepth, stack.length);
145-
line = line.replace(/^\s+/, '');
145+
line = line.replace(/^\s+/, '').replace(/\s+$/, '');
146146
if (lineDepth > minLineDepth) {
147147
line = Array(lineDepth - minLineDepth + 1).join('\t') + line;
148148
}

0 commit comments

Comments
 (0)