mirror of
https://github.com/thelounge/thelounge
synced 2024-11-23 12:33:07 +00:00
caa46042bf
Several ES6 additions are only available in strict mode. Example: > SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode Strict mode was also enabled in a few of our files already, and it is a good thing to have anyway.
16 lines
403 B
JavaScript
16 lines
403 B
JavaScript
"use strict";
|
|
|
|
/*
|
|
* This is a separate file for two reasons:
|
|
* 1. CSP policy does not allow inline javascript
|
|
* 2. It has to be a small javascript executed before all other scripts,
|
|
* so that the timeout can be triggered while slow JS is loading
|
|
*/
|
|
|
|
setTimeout(function() {
|
|
var element = document.getElementById("loading-slow");
|
|
|
|
if (element) {
|
|
element.style.display = "block";
|
|
}
|
|
}, 5000);
|