File tree 2 files changed +6
-2
lines changed
2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change 44
44
"license" : " MIT" ,
45
45
"dependencies" : {
46
46
"@babel/runtime" : " ^7.5.5" ,
47
- "@testing-library/dom" : " ^6.0.0"
47
+ "@testing-library/dom" : " ^6.0.0" ,
48
+ "@types/react-dom" : " *"
48
49
},
49
50
"devDependencies" : {
50
51
"@reach/router" : " ^1.2.1" ,
Original file line number Diff line number Diff line change 1
1
import { queries , Queries , BoundFunction } from '@testing-library/dom'
2
+ import { act as reactAct } from 'react-dom/test-utils'
2
3
3
4
export * from '@testing-library/dom'
4
5
@@ -43,4 +44,6 @@ export function cleanup(): void
43
44
* If that's not available (older version of react) then it
44
45
* simply calls the given callback immediately
45
46
*/
46
- export function act ( callback : ( ) => void ) : void
47
+ export const act : typeof reactAct extends undefined
48
+ ? ( callback : ( ) => void ) => void
49
+ : typeof reactAct
You can’t perform that action at this time.
0 commit comments