useWindowSize
Custom hook that tracks the size of the window.
Installation
npx sse-hooks add use-window-size
yarn dlx sse-hooks add use-window-size
pnpm dlx sse-hooks add use-window-size
deno run -A npm:sse-hooks add use-window-size
bunx sse-hooks add use-window-size
Usage
example.ts
import { useWindowSize } from "./{hooks file}";
const { width = 0, height = 0 } = useWindowSize();
console.log(`Window size: ${width} x ${height}`);
API
Parameters
| Prop | Default | Type |
|---|---|---|
options | - |
|
Returns
| Return Value | Default | Type |
|---|---|---|
height | - |
The height of the window. |
width | - |
The width of the window. |
Types Aliases
No specific type aliases defined for this component.
Changelog
useUserMedia
Custom hook that captures audio and video from the user's device. It handles permission errors, stream management, and cleanup automatically.
useConferenceSystem
A comprehensive hook for managing video conferencing state, including camera access, screen sharing, network monitoring, and automatic media quality adjustment.