Skip to content

Commit

Permalink
Update dependency usehooks-ts to v3 (#885)
Browse files Browse the repository at this point in the history
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: lukasIO <[email protected]>
  • Loading branch information
renovate[bot] and lukasIO authored Jun 18, 2024
1 parent 58f514e commit 7cd73d7
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 8 deletions.
5 changes: 5 additions & 0 deletions .changeset/small-sheep-check.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@livekit/components-react": patch
---

Update usehooks-ts to v3
2 changes: 1 addition & 1 deletion packages/react/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
"@livekit/components-core": "workspace:*",
"@react-hook/latest": "1.0.3",
"clsx": "2.1.1",
"usehooks-ts": "2.16.0"
"usehooks-ts": "3.1.0"
},
"peerDependencies": {
"@livekit/protocol": "^1.16.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/react/src/components/participant/VideoTrack.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ export const VideoTrack = /* @__PURE__ */ React.forwardRef<HTMLVideoElement, Vid
const mediaEl = React.useRef<HTMLVideoElement>(null);
React.useImperativeHandle(ref, () => mediaEl.current as HTMLVideoElement);

const intersectionEntry = useHooks.useIntersectionObserver(mediaEl, {});
const intersectionEntry = useHooks.useIntersectionObserver({ root: mediaEl.current });

const debouncedIntersectionEntry = useHooks.useDebounce(intersectionEntry, 3000);
const [debouncedIntersectionEntry] = useHooks.useDebounceValue(intersectionEntry, 3000);

React.useEffect(() => {
if (
Expand Down
10 changes: 5 additions & 5 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 7cd73d7

Please sign in to comment.