#125 Maybe make add_renderer instead of subclassing AppConfig?

Undetermined
migrated
nobody
None
core
defect
trivial
quickstart
2.1.5
2012-09-25
2011-10-18
No

In https://sourceforge.net/p/turbogears2/tg2tut/ci/a7950f8500936d8ba4218c9725dc6ba285a38b1e/tree/hiringpond/hiringpond/config/app_cfg.py I had to learn how to add/make a custom render I had to learn how to make a custom renderer. While this was a useful exercise, we might want to consider making a new method on the AppConfig class:

add_renderer(name, function)

It will take a name for the renderer, and a callable that will do the actual setup, template loading, etc. The end result would be something to allow for much easier adding without requiring subclassing AppConfig just to add a renderer.

I'm adding this as a ticket, rather than just doing it, since I might find other reasons to subclass AppConfig that would make the current model seem more valid/normal/proper than using the add_renderer function.

Discussion

    • status: open --> migrated
    • version: 2.1.3 --> 2.1.5