Revize 37f6ff02
Přidáno uživatelem Václav Honzík před téměř 3 roky(ů)
frontend/src/features/Auth/userReducer.ts | ||
---|---|---|
10 | 10 |
isLoggedIn: boolean |
11 | 11 |
} |
12 | 12 |
|
13 |
const initialState: UserState = { |
|
14 |
roles: [], |
|
15 |
isLoggedIn: false, |
|
16 |
username: '', |
|
17 |
} |
|
18 |
|
|
19 | 13 |
// All possible actions |
20 | 14 |
export enum AuthStateActions { |
21 | 15 |
LOG_IN = 'LOG_IN', |
... | ... | |
31 | 25 |
storage |
32 | 26 |
} |
33 | 27 |
|
28 |
const initialState: UserState = { |
|
29 |
roles: [], |
|
30 |
isLoggedIn: false, |
|
31 |
username: '', |
|
32 |
} |
|
33 |
|
|
34 |
|
|
34 | 35 |
const _authReducer = ( |
35 | 36 |
state: UserState = initialState, |
36 | 37 |
action: AnyAction |
Také k dispozici: Unified diff
re #9368 - redux slice for auth + axios interceptors start