diff --git a/package.json b/package.json
index 2257aeb5..69d41b1c 100644
--- a/package.json
+++ b/package.json
@@ -1,7 +1,7 @@
{
"name": "JSDoc",
"version": "3.0.0alpha",
- "revision": "1319671194463",
+ "revision": "1323214202201",
"description": "An automatic documentation generator for javascript.",
"keywords": [ "documentation", "javascript" ],
"licenses": [
diff --git a/templates/default/publish.js b/templates/default/publish.js
index e5f98a88..d2a5bcd4 100644
--- a/templates/default/publish.js
+++ b/templates/default/publish.js
@@ -96,7 +96,13 @@
types = f.type.names;
}
- f.signature = (f.signature || '') + ''+htmlsafe(types.length? ' :'+types.join('|') : '')+'';
+ if (types && types.length) {
+ types = _.map(types, function(t) {
+ return linkto(t, htmlsafe(t));
+ });
+ }
+
+ f.signature = (f.signature || '') + ''+(types.length? ' :'+types.join('|') : '')+'';
}
function addAttribs(f) {
@@ -134,18 +140,8 @@
//}
data.forEach(function(doclet) {
- doclet.signature = '';
- doclet.attribs = '';
-
- if (doclet.kind === 'member') {
- addSignatureType(doclet);
- addAttribs(doclet)
- }
-
- if (doclet.kind === 'constant') {
- addSignatureType(doclet);
- addAttribs(doclet)
- }
+ doclet.attribs = '';
+
if (doclet.examples) {
doclet.examples = doclet.examples.map(function(example) {
@@ -226,6 +222,18 @@
// do this after the urls have all been generated
data.forEach(function(doclet) {
doclet.ancestors = generateAncestry(doclet);
+
+ doclet.signature = '';
+
+ if (doclet.kind === 'member') {
+ addSignatureType(doclet);
+ addAttribs(doclet)
+ }
+
+ if (doclet.kind === 'constant') {
+ addSignatureType(doclet);
+ addAttribs(doclet)
+ }
});
var nav = '',