y lock into place to prevent rattling while cycling.\u003c\/li\u003e\n\u003cli\u003eThe unique hole pattern design lets you mount it either front-facing or sideways, whatever fits your bike best.\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cul class=\"attributesSpecification\"\u003e\n\u003cli\u003e\n\u003cdiv class=\"label\"\u003eProduct Type\u003c\/div\u003e\n\u003cdiv class=\"value\"\u003eBaskets\u003c\/div\u003e\n\u003c\/li\u003e\n\u003cli\u003e\n\u003cdiv class=\"label\"\u003eColour\u003c\/div\u003e\n\u003cdiv class=\"value\"\u003eBlack\u003c\/div\u003e\n\u003c\/li\u003e\n\u003cli\u003e\n\u003cdiv class=\"label\"\u003eSize\u003c\/div\u003e\n\u003cdiv class=\"value\"\u003eOne size\u003c\/div\u003e\n\u003c\/li\u003e\n\u003c\/ul\u003e"};
window._RestockRocketConfig.variantsInventoryPolicy = {46081976926434 : "deny",};
window._RestockRocketConfig.variantsInventoryQuantity = {46081976926434 : parseInt("1"),};
window._RestockRocketConfig.variantsPreorderCount = {46081976926434 : parseInt(""),};
wind
8f/restock-rocket-shopify-410/assets/restockrocket-collection.js'
window._RestockRocketConfig.scriptHost = window._RestockRocketConfig.scriptUrlProduct.substring(0, window._RestockRocketConfig.scriptUrlProduct.lastIndexOf('/') + 1)
window._RestockRocketConfig.host = 'https://app.restockrocket.io'
const SETTINGS_CACHE_DURATION = 15 * 60 * 1000; // 15 minutes in milliseconds
function checkSettingsExpiry(settings) {
try {
if (!settings || !settings.updated_at) {
console.debug('STOQ - Invalid settings data structure');
return null;
}
if (!settings.cache) {
console.debug('STOQ - settings caching disabled');
return null;
}
// Check if translations are enabled but missing from cache
// This handles the backfill period where DB has translations but metafield doesn't
if (settings.multi_language_enabled) {
if (!settings.translations) {
// Translations enabled but no translation data in metafield
// Meta
f (age
SETTINGS_CACHE_DURATION) {
console.debug('STOQ - settings changed recently, skipping cache');
return null;
}
return settings;
} catch (error) {
console.debug('STOQ - Error checking settings cache:', error);
return null;
}
}
function createRestockRocketContainer() {
const restockRocketContainer = document.createElement('div');
restockRocketContainer.id = 'restock-rocket';
document.body.appendChild(restockRocketContainer);
}
function createRestockRocketScript(scriptUrl) {
const restockRocketScriptElement = document.createElement('script');
restockRocketScriptElement.setAttribute('defer', 'defer');
restockRocketScriptElement.src = scriptUrl;
document.body.appendChild(restockRocketScriptElement);
}
createRestockRocketContainer()
console.debug('STOQ - extension activated')
function applyTranslations(settings) {
try {
// Skip translation logic entirely if multi-language is not enabled
if (!settings || Forks];
if (value !== null && value !== undefined && value !== '') {
settings[key] = value;
}
});
} else {
console.debug('STOQ - No translated fields found for locale:', normalizedLocale);
}
delete settings.translations;
return settings;
} catch (e) {
console.debug('STOQ - error applying translations:', e);
return settings;
}
}
// First try to get settings from metafields with expiry check
const cachedSettings = window._RestockRocketConfig.cachedSettings;
const validCachedSettings = cachedSettings ? checkSettingsExpiry(cachedSettings) : null;
if (validCachedSettings) {
console.debug('STOQ - using cached settings');
initializeScripts(validCachedSettings);
} else {
console.debug('STOQ - fetching fresh settings');
const headers = {
'X-Shopify-Shop-Domain': window._RestockRocketConfig.shop || window.Shopify.shop,
'ngrok-skip-browser-warning': 'skip'
};
if (window.Shopi
/ Dispatch custom event when app is loaded
const appLoadedEvent = new CustomEvent('stoq:loaded', {
detail: {
pageType: window._RestockRocketConfig.pageType,
enabled: settings.enable_app,
settings: settings
}
});
console.debug('STOQ - dispatching app loaded event');
window.dispatchEvent(appLoadedEvent);
}
}
function updateCartSellingPlans() {
// Wait for the API to be available with retries
const maxRetries = 10;
const retryDelay = 500;
function attemptCartCheck(attempt = 1) {
if (window._RestockRocket && window._RestockRocket.updateCartSellingPlans) {
window._RestockRocket.updateCartSellingPlans()
.then(hasUpdates => {
if (hasUpdates) {
console.debug('STOQ - cart selling plans updated successfully');
} else {
console.debug('STOQ - no cart selling plan updates needed');
}
})
.catch(error => {
conso
le.error('STOQ - error updating cart selling plans:', error);
});
} else if (attempt
<
maxRetries) {
console.debug(`STOQ - API not ready, retry ${attempt}/${maxRetries}`);
setTimeout(() => attemptCartCheck(attempt + 1), retryDelay);
} else {
console.debug('STOQ - API not loaded after max retries, skipping cart selling plan check');
}
}
attemptCartCheck();
}
Rear Suspension
Brakes
Brake Rotors
ProjektRideTyres
Buy Sell Ride Confident
Brake Pads
Tubes
Brake Spares
FAQ
Questions and answers
Tubeless
ForksSaddles
Seat Posts & Clamps
Please get in touch with a member of the team either by phone (Rear Suspension
01313745324
Pedals) or email (
[email protected]
) where on of the team will be more than happy to help.