Skip to content

Commit f14fc53

Browse files
authored
Merge pull request #483 from ruisaraiva19/develop
2 parents 37a1af5 + a2d70d7 commit f14fc53

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

pages/_document.tsx

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ import Document, { Html, Head, Main, NextScript } from 'next/document'
44
class MyDocument extends Document {
55
render() {
66
return (
7-
<Html lang="en">
7+
<Html lang="en" className="preload">
88
<Head />
9-
<body className="preload">
10-
<script src="/js/noflash.js" />
9+
<body>
10+
<script src="/js/noflash.js?v1" />
1111
<Main />
1212
<NextScript />
13-
<script src="/js/onload.js" />
13+
<script src="/js/onload.js?v1" />
1414
</body>
1515
</Html>
1616
)

public/js/onload.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
;(function () {
22
window.addEventListener('load', function () {
3-
document.body.classList.remove('preload')
3+
document.documentElement.classList.remove('preload')
44
})
55
})()

0 commit comments

Comments
 (0)