diff --git a/material/base.html b/material/base.html index 26ed8f866..b91933449 100644 --- a/material/base.html +++ b/material/base.html @@ -241,11 +241,11 @@ {% endblock %} {% block scripts %} - {% for path in config.extra_javascript %} - {% if path.endswith(".mjs") %} - + {% for script in config.extra_javascript %} + {% if script.path %} + {{ script | script_tag }} {% else %} - + {% endif %} {% endfor %} {% endblock %} diff --git a/src/base.html b/src/base.html index eb8205a5b..850821a3c 100644 --- a/src/base.html +++ b/src/base.html @@ -419,11 +419,13 @@ - {% for path in config.extra_javascript %} - {% if path.endswith(".mjs") %} - + {% for script in config.extra_javascript %} + + + {% if script.path %} + {{ script | script_tag }} {% else %} - + {% endif %} {% endfor %} {% endblock %}