Skip to content
Source
Sign inSign up
pingdotgg/t3code
Open History to see the last commit

atomRegistry.ts

9 lines368 Bytes

1import { RegistryContext } from "@effect/atom-react";
2import { AtomRegistry } from "effect/reactivity";
3import { createElement } from "react";
4​
5export const appAtomRegistry = AtomRegistry.make();
6​
7export function AppAtomRegistryProvider({ children }: React.PropsWithChildren) {
8 return createElement(RegistryContext.Provider, { value: appAtomRegistry }, children);
9}