-
-
Notifications
You must be signed in to change notification settings - Fork 260
Closed
Labels
bugSomething isn't workingSomething isn't workingtypingsTypescript public type definitions issuesTypescript public type definitions issues
Description
Example from the docs doesn't work with typescript (https://effector.dev/docs/api/effector/combine/#combine-with-primitives-and-objects)
const $a = createStore('a')
const b = 2
const c = [false]
const d = { value: 1 }
const $resultUsingComa = combine($a, b, c, d)TS error:
No overload matches this call.
Overload 1 of 18, '(a: Store<string>, b: Store<unknown>, c: Store<unknown>, fn: (a: string, b: unknown, c: unknown) => unknown): Store<unknown>', gave the following error.
Argument of type 'number' is not assignable to parameter of type 'Store<unknown>'.
Overload 2 of 18, '(stores_0?: Store<any> | undefined, ...stores_1: Store<any>[]): Store<[(Store<any> | undefined)?, ...any[]]>', gave the following error.
Argument of type 'number' is not assignable to parameter of type 'Store<any>'.
Relevant documentation
https://effector.dev/docs/api/effector/combine/#combine-with-primitives-and-objects
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingtypingsTypescript public type definitions issuesTypescript public type definitions issues