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