Skip to content

Commit b5c66b6

Browse files
committed
chore: set default placehodler size to negative value to simplify test env init
1 parent 057afca commit b5c66b6

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/SingleObserver/index.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,10 @@ export default function SingleObserver(props: SingleObserverProps) {
1919

2020
// ============================= Size =============================
2121
const sizeRef = React.useRef({
22-
width: 0,
23-
height: 0,
24-
offsetWidth: 0,
25-
offsetHeight: 0,
22+
width: -1,
23+
height: -1,
24+
offsetWidth: -1,
25+
offsetHeight: -1,
2626
});
2727

2828
// ============================= Ref ==============================

0 commit comments

Comments
 (0)