-
-
Notifications
You must be signed in to change notification settings - Fork 15.2k
Closed
Description
Repro:
type State = {
bar: unknown;
};
declare let preloadedState: State;
declare const reducer: Reducer<State>;
createStore(
reducer,
// Unexpected type error:
/* Argument of type 'State' is not assignable to parameter of type 'DeepPartial<State>'.
Types of property 'bar' are incompatible.
Type 'unknown' is not assignable to type 'DeepPartial<unknown> | undefined'.
Type 'unknown' is not assignable to type 'DeepPartial<unknown>'. */
preloadedState,
);
type StateDP = DeepPartial<State>;
declare let stateDP: StateDP;
// Unexpected type error:
// Type 'State' is not assignable to type 'DeepPartial<State>'
stateDP = preloadedState;timjchin and elevenpassin
Metadata
Metadata
Assignees
Labels
No labels