We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 787cb85 commit e165e44Copy full SHA for e165e44
src/act-compat.js
@@ -1,7 +1,8 @@
1
import * as React from 'react'
2
import * as DeprecatedReactTestUtils from 'react-dom/test-utils'
3
4
-const reactAct = React.act ?? DeprecatedReactTestUtils.act
+const reactAct =
5
+ typeof React.act === 'function' ? React.act : DeprecatedReactTestUtils.act
6
7
function getGlobalThis() {
8
/* istanbul ignore else */
0 commit comments