mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-07 18:31:46 +08:00
remove unnecessary check if observer is defined
This commit is contained in:
parent
d35ed61320
commit
d06ab1c64b
@ -45,7 +45,7 @@ const useMutationObserver = ({
|
|||||||
);
|
);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (observer && element?.current) {
|
if (element?.current) {
|
||||||
observer.observe(element.current, options);
|
observer.observe(element.current, options);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user