mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-01-01 21:30:30 +01:00
feat: allow nbb to work with cloudflare rocket loader 🚀
This commit is contained in:
@@ -5,9 +5,14 @@
|
||||
{{{end}}}
|
||||
|
||||
<script>
|
||||
window.addEventListener('DOMContentLoaded', function () {
|
||||
require(['forum/footer']);
|
||||
if (document.readyState === 'loading') {
|
||||
window.addEventListener('DOMContentLoaded', prepareFooter);
|
||||
} else {
|
||||
prepareFooter();
|
||||
}
|
||||
|
||||
function prepareFooter() {
|
||||
require(['forum/footer']);
|
||||
<!-- IF useCustomJS -->
|
||||
{{customJS}}
|
||||
<!-- ENDIF useCustomJS -->
|
||||
@@ -15,5 +20,5 @@
|
||||
$(document).ready(function () {
|
||||
ajaxify.coldLoad();
|
||||
});
|
||||
});
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user