import react from "react";

//#region ../react-intlayer/dist/esm/server/useLoadDynamic.mjs
const useLoadDynamic = (_key, promise) => {
	/** @ts-ignore remove error Property 'cache' does not exist on type 'typeof React'. */
	const cachedPromise = react.cache(async () => await promise)();
	return react.use(cachedPromise);
};

//#endregion
export { useLoadDynamic };
//# sourceMappingURL=useLoadDynamic.mjs.map