@lobehub/ui
Version:
Lobe UI is an open-source UI component library for building AIGC web apps
20 lines (17 loc) • 483 B
JavaScript
'use client';
import { createContext, memo, use } from "react";
import { jsx } from "react/jsx-runtime";
//#region src/Form/components/FormProvider.tsx
const FormContext = createContext({});
const FormProvider = memo(({ children, config }) => {
return /* @__PURE__ */ jsx(FormContext, {
value: config,
children
});
});
const useFormContext = () => {
return use(FormContext);
};
//#endregion
export { FormProvider, useFormContext };
//# sourceMappingURL=FormProvider.mjs.map