code: async function loadImageSize(url, cache) {
    let cacheKey = 'image#' + url;
    let ttl = 24 * 60 * 60 * 1000; // 1 day
  
    // Try get image dimensions from cache
    const cached = await cache.get(cacheKey);
    // If image dimensions in cache and not expired - return it
    if (cached && cached.ts > Date.now() - ttl) return cached.dimensions;
  
    // If no data in cache - fetch
  
    let dimensions;
  
    try {
      dimensions = await size(url);
    } catch (err) {
      // Suppress errors for broken data, return `null` instead
      if (err.code === 'ECONTENT') return null;
      throw err;
    }
  
    // Save data to cache
    await cache.set(cacheKey, { dimensions: dimensions, ts: Date.now() });
  
    return dimensions;
  }
docs: Load image dimensions by url  - url (String) - cache (Object)