File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed
components/Auth/Auth/ProgressBar Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change 6
6
faUserSecret ,
7
7
} from '@fortawesome/free-solid-svg-icons' ;
8
8
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome' ;
9
+ import { IconProp } from '@fortawesome/fontawesome-svg-core' ;
9
10
interface user {
10
11
formNumber ?: number ;
11
12
completed ?: boolean ;
@@ -37,7 +38,7 @@ export default function UserDetails(props: user): JSX.Element {
37
38
}
38
39
onClick = { props . handleForm1 }
39
40
>
40
- < FontAwesomeIcon icon = { faUser } />
41
+ < FontAwesomeIcon icon = { faUser as IconProp } />
41
42
</ button >
42
43
</ div >
43
44
< div >
@@ -52,7 +53,7 @@ export default function UserDetails(props: user): JSX.Element {
52
53
}
53
54
onClick = { props . handleForm2 }
54
55
>
55
- < FontAwesomeIcon icon = { faUserSecret } />
56
+ < FontAwesomeIcon icon = { faUserSecret as IconProp } />
56
57
</ button >
57
58
</ div >
58
59
< div >
@@ -62,7 +63,7 @@ export default function UserDetails(props: user): JSX.Element {
62
63
! props . completed ? styles . levelInitiated : styles . levelCompleted
63
64
}
64
65
>
65
- < FontAwesomeIcon icon = { faCode } />
66
+ < FontAwesomeIcon icon = { faCode as IconProp } />
66
67
</ button >
67
68
</ div >
68
69
</ div >
Original file line number Diff line number Diff line change 1
1
import { TypedUseSelectorHook , useDispatch , useSelector } from 'react-redux' ;
2
- import type { RootState , AppDispatch } from './store' ;
3
-
2
+ import type { RootState } from './store' ;
3
+ import { Dispatch } from 'react' ;
4
4
// Use throughout your app instead of plain `useDispatch` and `useSelector`
5
- export const useAppDispatch = ( ) : AppDispatch => useDispatch < AppDispatch > ( ) ;
5
+ export const useAppDispatch = < T > ( ) : Dispatch < T > => useDispatch < Dispatch < T > > ( ) ;
6
6
export const useAppSelector : TypedUseSelectorHook < RootState > = useSelector ;
You can’t perform that action at this time.
0 commit comments