@wordpress/widget-dashboard
Version:
Stateless rendering engine for widget dashboards: the WidgetDashboard compound component and its grid-settings kit.
19 lines (18 loc) • 509 B
JavaScript
// packages/widget-dashboard/src/context/widget-context.tsx
import { createContext, useContext } from "@wordpress/element";
import { jsx } from "react/jsx-runtime";
var WidgetContext = createContext(null);
function WidgetContextProvider({
value,
children
}) {
return /* @__PURE__ */ jsx(WidgetContext.Provider, { value, children });
}
function useWidgetContext() {
return useContext(WidgetContext);
}
export {
WidgetContextProvider,
useWidgetContext
};
//# sourceMappingURL=widget-context.mjs.map