File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -10,8 +10,11 @@ function StoreFactory() {
10
10
let state : GlobalState = { } ;
11
11
const listeners = new Set < ( ) => void > ( ) ;
12
12
13
- const setState = ( dispatchAction : ( ( payload : GlobalState ) => GlobalState ) | GlobalState ) => {
14
- state = typeof dispatchAction === 'function' ? dispatchAction ( state ) : state ;
13
+ const setState = (
14
+ dispatchAction : ( ( payload : GlobalState ) => GlobalState ) | GlobalState ,
15
+ ) => {
16
+ state =
17
+ typeof dispatchAction === 'function' ? dispatchAction ( state ) : state ;
15
18
16
19
for ( const listener of listeners ) {
17
20
listener ( ) ;
Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ export type StateMachineOptions = Partial<{
26
26
name : string ;
27
27
middleWares : MiddleWare [ ] ;
28
28
storageType : Storage ;
29
- persist : typeof PERSIST_OPTION [ keyof typeof PERSIST_OPTION ] ;
29
+ persist : ( typeof PERSIST_OPTION ) [ keyof typeof PERSIST_OPTION ] ;
30
30
} > ;
31
31
32
32
declare global {
You can’t perform that action at this time.
0 commit comments