Cache all base scripts

This commit is contained in:
George Lacey 2021-05-18 18:04:20 +01:00
parent 0ad734eb72
commit c3825efe26
2 changed files with 3 additions and 4 deletions

View File

@ -6,21 +6,21 @@
{% load static %}
{% load cache %}
{% block script %}
{% cache 3600 sass %}
{% cache 3600 script %}
<link rel="shortcut icon" href="{% static 'favicon.ico' %}">
{% load compress %}
{% compress css %}
<link type="text/x-scss" href="{% static 'theme.scss' %}" rel="stylesheet" media="screen">
{% endcompress %}
{% endcache %}
{% block script %}
{% endblock %}
<style>{% block style %}{% endblock %}</style>
<title>{% block title %}Title{% endblock %}</title>
</head>
<body>
{% cache 3600 navbar %}
<nav class="navbar navbar-expand-md navbar-dark bg-secondary mb-2">
<div class="container-fluid">

View File

@ -4,7 +4,6 @@
{% block title %}Borg Summary{% endblock %}
{% block script %}
{{block.super}}
<script src="https://cdn.jsdelivr.net/npm/chart.js"></script>
{{ hour_list|json_script:"hour_list" }}
<script src="{% static 'js/index.js' %}"></script>