Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: Deprecate BaseCollector and BaseRenderer
The BaseCollector and BaseRenderer are merged into the BaseHandler (as mixins for now). Developers are still able to create collectors and renderers using these deprecated base classes, and pass instances of them when creating their handler. All the methods of the deprecated bases can now be defined on the BaseHandler subclass itself. Handlers can then be instantiated by passing the handler's name, the theme and the optional custom templates folder name/path. Reasoning: often times, the renderer and the collector need to communicate or share data. For example, the Crystal renderer uses the collector to lookup names when creating cross-references. The Python handlers are able to filter members when collecting/returning data, and need the same members list when rendering, to order the elements based on that list. This change is the first of two, where the second change will deprecate the use of `selection` and `rendering` keys in the YAML options or MkDocs configuration, in favor of a single `options` key that both the collection and rendering process will share.
- Loading branch information
Showing
4 changed files
with
132 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters