diff --git a/src/index.d.ts b/src/index.d.ts index 8c03719..95b766a 100644 --- a/src/index.d.ts +++ b/src/index.d.ts @@ -83,12 +83,12 @@ declare namespace Charm { * changes. Returns a cleanup function that unsubscribes the callback. * * Note that dependencies are only evaluated once when the effect is created, - * conditional dependencies may not work as expected. + * so conditional dependencies may not work as expected. * * @param callback The function to run. * @returns A function that unsubscribes the callback. */ - function effect(callback: () => void): Cleanup; + function effect(callback: () => Cleanup | void): Cleanup; /** * Returns the result of the function without subscribing to changes. If a