Skip to content

Commit ac12c3e

Browse files
committed
Correctly generate index.html
1 parent b37c593 commit ac12c3e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/webdoc-default-template/publish.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ exports.publish = (options /*: PublishOptions */) => {
5252
const docTree = options.documentTree;
5353
const outDir = path.normalize(options.config.opts.destination);
5454
const index = linker.createURI("index");
55+
const indexRelative = index.slice(linker.siteRoot.length + 1);
5556

5657
fse.ensureDir(outDir);
5758

@@ -79,7 +80,7 @@ exports.publish = (options /*: PublishOptions */) => {
7980

8081
outStaticFiles(outDir);
8182
outExplorerData(outDir, crawlData);
82-
outMainPage(path.join(outDir, index), pipeline, options.config);
83+
outMainPage(path.join(outDir, indexRelative), pipeline, options.config);
8384
outIndexes(outDir, pipeline, options.config, crawlData.index);
8485
outReference(outDir, pipeline, options.config, docTree);
8586
};

0 commit comments

Comments
 (0)