import "./log-records.js";
import { getLogger } from "./micro-frontend/index.js";
const initServiceWorker = (swDest = "") => {
  const logger = getLogger() || console;
  if (false) {
    window.addEventListener("load", () => {
      navigator.serviceWorker.register(`${swDest.replace(/\/?$/, "/")}sw.js`).then(() => {
        logger.debug("Service Worker registered");
      }).catch((registrationError) => {
        logger.error({
          ...logRecords.SERVICE_WORKER_FAILED,
          exception: registrationError
        });
      });
    });
  }
};
export {
  initServiceWorker
};
