mirror of
https://github.com/timmypidashev/web.git
synced 2026-04-14 02:53:51 +00:00
5 lines
175 B
TypeScript
5 lines
175 B
TypeScript
export function prefersReducedMotion(): boolean {
|
|
if (typeof window === "undefined") return false;
|
|
return window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
}
|