Skip to content

Commit 399a552

Browse files
committed
allow act in old React versions
1 parent e24783e commit 399a552

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/test-utils.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,8 @@ function getActFn() {
7777
) {
7878
return undefined;
7979
}
80+
// biome-ignore lint/suspicious/noTsIgnore: Needed for compatibility with multiple React versions
81+
// @ts-ignore
8082
return typeof React.act === "function"
8183
? // @ts-ignore
8284
React.act

0 commit comments

Comments
 (0)