22 lines
580 B
Plaintext
22 lines
580 B
Plaintext
|
<%- __js('js/libs/pjax.min.js') %>
|
||
|
<script>
|
||
|
window.addEventListener('DOMContentLoaded', () => {
|
||
|
const pjax = new Pjax({
|
||
|
selectors: [
|
||
|
'head title',
|
||
|
'.page-container',
|
||
|
'.pjax',
|
||
|
],
|
||
|
cacheBust: false,
|
||
|
currentUrlFullReload: false,
|
||
|
timeout: 0
|
||
|
});
|
||
|
|
||
|
window.addEventListener('pjax:complete', () => {
|
||
|
|
||
|
KEEP.refresh();
|
||
|
pjax.executeScripts(document.querySelectorAll('script[data-pjax], .pjax script'));
|
||
|
});
|
||
|
});
|
||
|
</script>
|