const cache = /* @__PURE__ */ new Map();
const loader = async (locale) => {
  if (cache.has(locale)) return cache.get(locale);
  const messages = await $fetch(`/api/locale/${locale}`);
  cache.set(locale, messages);
  return messages;
};

export { loader as default };
