'use strict';

/*!
 * @techmely/utils
 * Copyright(c) 2021-2024 Techmely <techmely.creation@gmail.com>
 * MIT Licensed
 */


// src/requestIdleCallback.ts
function requestIdleCallbackShim(cb) {
  const start = Date.now();
  return setTimeout(() => {
    cb({
      didTimeout: false,
      timeRemaining: () => Math.max(0, 50 - (Date.now() - start))
    });
  }, 1);
}
var requestIdleCallback = typeof window !== "undefined" ? window.requestIdleCallback || requestIdleCallbackShim : requestIdleCallbackShim;

exports.requestIdleCallback = requestIdleCallback;
