Skip to content

Commit

Permalink
fix: revert jsii-docgen to produce smaller docs (#4594)
Browse files Browse the repository at this point in the history
In #4577 `jsii-docgen` got updated to the current v10 version line.

Unfortunately this update brings the new addition of summary tables for parameters and class methods to generated documentation. For this package that means an increase in file-size from 650kb per language to ca. 4.5mb per language. This increase in turn breaks the generation of the `cdk8s` website because `mkdocs` cannot handle such large files.

As an immediate solution, this PR reverts the version of `jsii-docgen` back to v3.

Mid-term, the way forward would probably be to use the `--split-by-submodules` options and adjust the `cdk8s` website script to accommodate for it. Or if that doesn't work (because submodule docs are still to large), we will need to add new features into `jsii-docgen` to allow for more control of the output. Finally, the docs process here (or in `cdk8s`) could switch to the json output format and implement their own, custom markdown rendering.
  • Loading branch information
mrgrain authored Aug 30, 2024
1 parent 66c441e commit 23453ae
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 22 deletions.
2 changes: 1 addition & 1 deletion .projen/deps.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .projenrc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ const importTask = project.addTask('import', {
});
project.compileTask.prependSpawn(importTask);

project.addDevDeps('jsii-docgen@^3.8.31');
const docgenTask = project.tasks.tryFind('docgen')!;
docgenTask.reset();
for (const lang of ['typescript', 'python', 'java']) {
Expand Down
2 changes: 1 addition & 1 deletion package.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

56 changes: 36 additions & 20 deletions yarn.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 23453ae

Please sign in to comment.