Description
Search terms
module index page
Question
This is related to my typedoc plugin which can merge the content of modules and using it on a monorepo project.
Without using the plugin on the monorepo project the main page looks like this:
With using the plugin to merge modules (in this case they equal the projects having the same name) the module page looks like this:
As you can see class "C" is missing in the index but shows up in the navigation on the left. The question is why?
What I think the problem is:
When the plugin is used with TypeDoc's entryPointStrategy
set to packages
the plugin is listening to the even Application.EVENT_PROJECT_REVIVE
and merges the modules when this event is emitted by TypeDoc: https://github.com/krisztianb/typedoc-plugin-merge-modules/blob/master/src/plugin.ts#L63
As I understand the code TypeDoc uses a CategoryPlugin
to create the model used for rendering the module index. It seems to me that the index is generated before the plugin is merging the modules. Therefore the index is outdated in the end. Do you think that this is the case? If so how could this be fixed?
How to reproduce
I added automated tests to the plugin repo which can be used to reproduce the problem: https://github.com/krisztianb/typedoc-plugin-merge-modules/tree/master/test/merge-module-monorepo
You can use npm install
followed by npm run build
and npm test
to run the tests and see the result.