Skip to content
Snippets Groups Projects
Unverified Commit f7b1e292 authored by Fredrik Jonsson's avatar Fredrik Jonsson Committed by GitHub
Browse files

Merge pull request #1987 from OpenTechFund/enhancement/move-main-js-to-bottom

Move main.js to bottom and create main-top.js with the bits that need…
parents afdd8272 e56da9c0
No related branches found
No related tags found
No related merge requests found
(function ($) {
'use strict';
// IE 11 does not support classList.replace.
// document.querySelector('html').classList.replace('no-js', 'js');
$('html').removeClass('no-js').addClass('js');
})(jQuery);
......@@ -2,10 +2,6 @@
'use strict';
// IE 11 does not support classList.replace.
// document.querySelector('html').classList.replace('no-js', 'js');
$('html').removeClass('no-js').addClass('js');
let Search = class {
static selector() {
return '.js-search-toggle';
......
......@@ -33,7 +33,7 @@
<script src="{% static 'js/jquery.min.js' %}"></script>
<script src="{% static 'js/js.cookie.min.js' %}"></script>
<script src="{% static 'js/main.js' %}"></script>
<script src="{% static 'js/main-top.js' %}"></script>
</head>
<body class="{% block body_class %}light-grey-bg template-{{ page.get_verbose_name|slugify }}{% endblock %}">
......@@ -111,6 +111,7 @@
</main>
<footer class="footer"></footer>
<script src="{% static 'js/main.js' %}"></script>
{% block extra_js %}{% endblock %}
</body>
</html>
......@@ -58,7 +58,7 @@
<link rel="stylesheet" href="{% static 'css/print.css' %}" media="print">
<script src="{% static 'js/jquery.min.js' %}"></script>
<script src="{% static 'js/main.js' %}"></script>
<script src="{% static 'js/main-top.js' %}"></script>
</head>
<body class="{% block body_class %}template-{{ page.get_verbose_name|slugify }}{% endblock %}">
......@@ -201,6 +201,7 @@
new google.translate.TranslateElement({pageLanguage: 'en', layout: google.translate.TranslateElement.InlineLayout.SIMPLE, autoDisplay: false}, 'google_translate_element');
}
</script>
<script src="{% static 'js/main.js' %}"></script>
{% block extra_js %}{% endblock %}
</body>
</html>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment