{"library":"react-responsive","type":"library","category":null,"description":"react-responsive is a well-established and actively maintained library (current stable version 10.0.1) that simplifies the integration of CSS media queries into React applications. It provides a declarative API for responsive design, allowing developers to render components or apply logic based on viewport characteristics. The library offers two primary interfaces: the modern `useMediaQuery` hook (introduced in v8.0.0) for functional components and a `MediaQuery` component (using render props) for class components or older patterns. Key differentiators include its support for both hooks and component-based approaches, convenient camel-cased shorthand properties for media query expressions, and a `device` prop for explicitly setting device characteristics, which is crucial for server-side rendering (SSR) and testing environments. It also ships with comprehensive TypeScript types, ensuring robust development. The library maintains a steady release cadence, focusing on stability and modern React paradigms.","language":"javascript","status":"active","version":"10.0.1","tags":["javascript","css","react-component","viewport","react","mobile","media queries","respond","media query","typescript"],"install":[{"cmd":"npm install react-responsive","imports":["import { useMediaQuery } from 'react-responsive'","import MediaQuery from 'react-responsive'","import type { UseMediaQueryOptions } from 'react-responsive'"]},{"cmd":"yarn add react-responsive","imports":[]},{"cmd":"pnpm add react-responsive","imports":[]}],"homepage":"https://contra.io/react-responsive","github":"https://github.com/yocontra/react-responsive","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/react-responsive","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/react-responsive/compatibility"},"provenance":{"verified_status":null,"verified_at":null,"last_verified":"Wed Jun 17","next_check":"Sat Jul 18","install_tag":null}}