Hello,
I’m facing an issue, on Firefox only, with the shipping.selected event:
I added a jquery datepicker in the shipping step that is launched as soon as the shipping method event is triggered:
document.addEventListener("snipcart.ready", () => {
Snipcart.events.on("shipping.selected", () => {
console.log("Shipping event triggered");
let datePicker = $('[id*="dateLivraison"]');
datePicker.datepicker({ ... });
});
});
It works well on Chrome, but I noticed the shipping.method event is triggered on Firefox only once the user clicked on a shipping method.
Which means that if the user don’t select any shipping method (= he is satisfied by the default selected shipping method), the event is not triggered and therefore the datepicker isn’t loaded.
HERE is the website, in development.
You need to select a shipping address in Switzerland and use 1204 as postcode (delivery is restricted by postcode)
Hope you can help me with that!
Thanks!