Gab Social. All are welcome.
This commit is contained in:
9
app/javascript/gabsocial/ready.js
Normal file
9
app/javascript/gabsocial/ready.js
Normal file
@@ -0,0 +1,9 @@
|
||||
'use strict';
|
||||
|
||||
export default function ready(loaded) {
|
||||
if (['interactive', 'complete'].includes(document.readyState)) {
|
||||
loaded();
|
||||
} else {
|
||||
document.addEventListener('DOMContentLoaded', loaded);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user