Templates
DjangoKit apps use standard Django templates. It includes a default base template djangokit/app.html that you can extend and customize or replace with your own version.
The head section contains the following blocks:
meta— meta tagstitle— title tagfavicon— favicon linklinks— arbitrary<link>s (e.g. forrel="me"links)stylesheets— stylesheet links (and/or<style>s)head_scripts— script tags (typicallydeferred)
The body section contains the following blocks:
layout— page layoutscripts— script tags
Customization
Depending on the level of customization needed:
- Add
routes/app.htmlto your project with{% extends "djangokit/app.html" %}and override blocks as needed. - Add
routes/app.htmlto your project without theextendsand create an entirely custom template.
Note
To change the global stylesheet(s) or global body scripts, you can set djangokit.global_stylesheets and/or djangokit.global_scripts in your project's settings.public.toml file instead of customizing the main template.