Re: Dynamic load pages [JS Snipet]
Reply #9 –
Unlikely: https://jsperf.com/regex-vs-split/2
I haven't tried this, but I would assume it's incompatible with the way I call my quick quote script https://github.com/Frenzie/elk-quick-quote/blob/da6090639d63ff1b51f67891723a85a28eab012e/quickQuote.js#L384
Off the top of my head I'm thinking something like
var dynamicLoadPagesEvent = document.createEvent('Event');
dynamicLoadPagesEvent.initEvent('dynamic-load-pages:load-next', true, true);
document.body.dispatchEvent(dynamicLoadPagesEvent);
Then we should be able to act on it like this:
document.body.addEventListener('dynamic-load-pages:load-next', initializeQuickQuote, false);