diff --git a/packages/core/src/atom.ts b/packages/core/src/atom.ts index 69068eadd..f67dbd8e7 100644 --- a/packages/core/src/atom.ts +++ b/packages/core/src/atom.ts @@ -671,7 +671,7 @@ function onCall(this: Action, cb: Fn): Unsubscribe { }) } -export function atom(initState: (ctx: CtxSpy) => T, name?: string): Atom +export function atom(callback: (ctx: CtxSpy) => T, name?: string): Atom export function atom(initState: T, name?: string): AtomMut export function atom( initState: T | ((ctx: CtxSpy) => T),