fix: use dynamic path for locale javascript
This commit is contained in:
parent
656e29c72b
commit
1b8e6164ed
1 changed files with 5 additions and 1 deletions
|
@ -27,7 +27,11 @@
|
|||
<script src="{% static 'umap/vendors/dompurify/purify.js' %}" defer></script>
|
||||
<script src="{% static 'umap/vendors/colorbrewer/colorbrewer.js' %}" defer></script>
|
||||
<script src="{% static 'umap/vendors/simple-statistics/simple-statistics.min.js' %}" defer></script>
|
||||
{% if locale %}<script src="{% static 'umap/locale/fr.js' %}" defer></script>{% endif %}{# TODO: handle dynamic locale! #}
|
||||
{% if locale %}
|
||||
{% with 'umap/locale/'|add:locale|add:'.js' as path %}
|
||||
<script src="{% static path %}" defer></script>
|
||||
{% endwith %}
|
||||
{% endif %}
|
||||
<script src="{% static 'umap/js/umap.core.js' %}" defer></script>
|
||||
<script src="{% static 'umap/js/umap.autocomplete.js' %}" defer></script>
|
||||
<script src="{% static 'umap/js/umap.popup.js' %}" defer></script>
|
||||
|
|
Loading…
Reference in a new issue