djblets.extensions.templatetags.djblets_extensions¶
Registers a place where TemplateHooks can render to.
Outputs the URL to the given static media file provided by an extension.
This works like the {% static %} template tag, but takes an extension and generates a URL for the media file within the extension.
This is meant to be used with
djblets.extensions.staticfiles.ExtensionFinder
.
Outputs HTML to import an extension’s CSS bundle.
Outputs HTML to import an extension’s JavaScript bundle.
Load all CSS bundles that can be rendered on the current page.
This will include all “default” bundles and any with an
apply_to
containing a URL name matching the current page.Parameters: - context (django.template.Context) – The template context.
- extension_manager_key (unicode) – The key for the extension manager for these bundles.
- default_bundles (unicode) – A string containing a comma-separated list of bundles to always
include. Defaults to
"default"
.
Returns: The HTML used to include the bundled content.
Return type:
Load all JavaScript bundles that can be rendered on the current page.
This will include all “default” bundles and any with an
apply_to
containing a URL name matching the current page.Parameters: - context (django.template.Context) – The template context.
- extension_manager_key (unicode) – The key for the extension manager for these bundles.
- default_bundles (unicode) – A string containing a comma-separated list of bundles to always
include. Defaults to
"default"
.
Returns: The HTML used to include the bundled content.
Return type:
Initializes all JavaScript extensions.
Each extension’s required JavaScript files will be loaded in the page, and their JavaScript-side Extension subclasses will be instantiated.