Jump to >

This documentation covers the in-development release of Djblets. You can see the latest stable docs or all previous versions.

djblets.template.loaders.conditional_cached

class Loader(engine, loaders)[source]

Caches template loading results only if not in DEBUG mode.

This extends Django’s built-in ‘cached’ template loader to only perform caching if settings.DEBUG is False. That helps to keep the site nice and speedy when in production, without causing headaches during development.