diff --git a/src/charm/src/index.d.ts b/src/charm/src/index.d.ts index e31bf06..676662f 100644 --- a/src/charm/src/index.d.ts +++ b/src/charm/src/index.d.ts @@ -16,7 +16,10 @@ declare namespace Charm { * @param state The next state or a function that produces the next state. * @returns The current state, if no arguments are provided. */ - type Atom = (state?: State | ((prev: State) => State)) => State; + interface Atom { + (): State; + (nextState: State | ((prevState: State) => State)): void; + } /** * A function that depends on one or more atoms and produces a value. Can be