Add a early js script.

This commit is contained in:
Fredrik Jonsson 2020-08-24 02:08:30 +02:00
commit 88054afa22

13
assets/js/script-early.js Normal file
View file

@ -0,0 +1,13 @@
/**
* @file
* A JavaScript file for the theme. Runs first, before jQuery etc. have loaded.
*/
(function () {
'use strict';
// Add a js class to the html-tag when JavsScript is active.
document.querySelector('html').classList.replace('nojs', 'js');
})();