// This code is done to force reload the page when the back button is hit (which allows to fix stale data on cart, for instance) if (performance.navigation.type === 2) { location.reload(true); }