Use jinja macros instead of includes
Description
Way easier to understand now. Still not trivial, but much less magic. See https://jinja.palletsprojects.com/en/3.1.x/templates/#macros
Checklist
Please confirm that this pull request has done the following:
- [ ] Tests added
-
Documentation added (where applicable) -
Changelog item added to changelog/
Edited by Zebedee Nicholls