new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

Mantine · all subjects

hooks/viewport

4 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

useViewportSize hook returns viewport dimensions

The useViewportSize hook returns an object with width and height properties containing the current viewport's dimensions. The width and height are numbers representing pixels.

useViewportSize subscribes to resize and orientationchange events

The useViewportSize hook automatically subscribes to resize and orientationchange events to update the viewport dimensions when the window is resized or the device orientation changes.

useViewportSize returns zero dimensions during SSR

During server-side rendering, the useViewportSize hook returns { width: 0, height: 0 } because viewport dimensions are not available on the server.

useViewportSize function signature

The useViewportSize hook has the following TypeScript signature: function useViewportSize(): { height: number; width: number; }. It takes no parameters and returns an object with height and width properties, both of type number.

Give your agent this brain