JSON to Media Query String Converter
JSON →json2mq is a JavaScript utility that translates plain JavaScript objects or JSON structures into valid CSS media query strings. Its current and only stable version is 0.2.0, which was published over eleven years ago, signifying that the package is no longer actively maintained or developed. The library automatically appends 'px' to numeric dimension values, handles various media types (e.g., 'screen', 'handheld'), and supports negations. A key differentiator is its straightforward, declarative input format for generating potentially complex CSS media query syntax, including support for multiple queries via an array of objects. Due to its age, it predates modern JavaScript module systems and TypeScript integration.
Traffic · last 30 days ↑250% vs prev 7d
top countries 🇺🇸 United States · 🇨🇦 Canada · 🇫🇷 France · 🇩🇪 Germany · 🇫🇮 Finland