diff options
Diffstat (limited to 'assets/js/main.js')
| -rw-r--r-- | assets/js/main.js | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/assets/js/main.js b/assets/js/main.js index 5da93ed..936bf37 100644 --- a/assets/js/main.js +++ b/assets/js/main.js @@ -10,7 +10,9 @@ class Main { await this.Get() } - #Loading() {} + #Loading() { + new Loading().Stop() + } async Get(x) { const object = { session: document.cookie, @@ -32,6 +34,7 @@ class Main { const section = document.getElementById('main') this.#LoadCSS(output.css).then(output => { + this.#Loading() section.innerHTML = DOMPurify.sanitize(this.output.html) this.output.js.map(file => { const script = document.createElement('script') @@ -39,11 +42,9 @@ class Main { this.object.body.appendChild(script) }) }) - - //section.innerHTML = DOMPurify.sanitize(output.html) }) } - async #LoadCSS (files) { + async #LoadCSS(files) { const promises = files.map(file => { return new Promise(res => { const link = document.createElement('link') |
