We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e0f5a4e commit 10334f3Copy full SHA for 10334f3
src/provider.tsx
@@ -21,7 +21,7 @@ export const Provider = function<S extends Store>(props: PropsWithChildren<Props
21
22
const [initialized, setInitialized] = useState(false)
23
function onChange(value: StoreV<S>) {
24
- !initialized && setInitialized(true)
+ if (!initialized) setInitialized(true)
25
container.state = value
26
container.notify()
27
}
0 commit comments