Skip to content

Commit 703ef77

Browse files
authored
Fix compat doc script (#5605)
1 parent 4a834d8 commit 703ef77

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

scripts/docgen-compat/generate-docs.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,12 @@ const { api: apiType, source: sourceFile } = yargs
3939
.version(false)
4040
.help().argv;
4141

42-
const docPath = path.resolve(`${__dirname}/html/${apiType}`);
42+
const destinationDir = apiType === 'js' ? 'js/v8' : apiType;
43+
const docPath = path.resolve(`${__dirname}/html/${destinationDir}`);
4344
const contentPath = path.resolve(`${__dirname}/content-sources/${apiType}`);
4445
const tempHomePath = path.resolve(`${contentPath}/HOME_TEMP.md`);
4546
const tempNodeSourcePath = path.resolve(`${__dirname}/index.node.d.ts`);
46-
const devsitePath = `/docs/reference/${apiType}/`;
47+
const devsitePath = `/docs/reference/${destinationDir}/`;
4748

4849
/**
4950
* Strips path prefix and returns only filename.

0 commit comments

Comments
 (0)