You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ABasePlugin._addSourceToProject() is only called once for the lifetime of a typedoc run, but this means that when you run typedoc --watch, the added sources aren't present in the project when later calls to findModuleRoot are made. This causes the pages plugin to crash with errors when trying to process pages for a subsequent build.
What did you expected ?
The extra sources should be added on each resolve begin event, so that they're present in all builds, not just the first one. Removing the once() wrapper fixes the issue for me.
The text was updated successfully, but these errors were encountered:
A similar issue exists with DefaultPagesRenderer in the pages plugin: the constructor is only run once, and there is code in it that should be run on every RendererEvent.BEGIN. (The bits from const modulesPages to event.urls =.) Without them, the pages are not actually rendered on the second or following watch runs.
As far as I can tell, these two issues are the only things stopping --watch from working with the pages plugin on Typedoc 0.25. I've written a script that monkeypatches fixes for them (and patches the default theme to add in the menus) and it seems to work fine now for me (combined with the "options" workaround from #525), but of course others may have different results.
Plugin
@knodes/typedoc-pluginutils
Typedoc plugin(s) version(s)
@knodes/[email protected], @knodes/[email protected]
Typedoc version
0.25.4
Describe the problem
ABasePlugin._addSourceToProject()
is only called once for the lifetime of a typedoc run, but this means that when you runtypedoc --watch
, the added sources aren't present in the project when later calls to findModuleRoot are made. This causes the pages plugin to crash with errors when trying to process pages for a subsequent build.What did you expected ?
The extra sources should be added on each resolve begin event, so that they're present in all builds, not just the first one. Removing the
once()
wrapper fixes the issue for me.The text was updated successfully, but these errors were encountered: