diff --git a/docs/processors/index-page.js b/docs/processors/index-page.js index ed770ef83c..0681e621bf 100644 --- a/docs/processors/index-page.js +++ b/docs/processors/index-page.js @@ -12,7 +12,7 @@ module.exports = { currentVersion = config.get('currentVersion'); contentsFolder = config.get('rendering.contentsFolder'); }, - process: function(docs) { + process: function(docs, config) { docs.push({ docType: 'index-page', id: 'index-page', @@ -20,5 +20,14 @@ module.exports = { template: 'index.template.html', outputPath: contentsFolder + '/api/index.md' }); + if (config.get('versionData').latest.name !== currentVersion) { + docs.push({ + docType: 'index-page', + id: 'index-page', + currentVersion: currentVersion, + template: 'index.template.html', + outputPath: contentsFolder + '/api/index.md' + }); + } } };