chore(doc-gen): only clone docs that are actually being re-exported to a new module
Closes #1353
This commit is contained in:
parent
8b97cf1479
commit
896a1564ef
|
@ -20,11 +20,13 @@ module.exports = function cloneExportedFromDocs(modules, EXPORT_DOC_TYPES) {
|
||||||
'Referenced in "@exportedAs" tag on class: "' + doc.moduleDoc.id + '/' + doc.name + '"');
|
'Referenced in "@exportedAs" tag on class: "' + doc.moduleDoc.id + '/' + doc.name + '"');
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
// Add a clone of export to its "exportedAs" module
|
if(exportedAsModule !== doc.moduleDoc) {
|
||||||
var clonedDoc = _.clone(doc);
|
// Add a clone of export to its "exportedAs" module
|
||||||
clonedDoc.moduleDoc = exportedAsModule;
|
var clonedDoc = _.clone(doc);
|
||||||
exportedAsModule.exports.push(clonedDoc);
|
clonedDoc.moduleDoc = exportedAsModule;
|
||||||
extraPublicDocs.push(clonedDoc);
|
exportedAsModule.exports.push(clonedDoc);
|
||||||
|
extraPublicDocs.push(clonedDoc);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue