Introducing Socket Firewall: Free, Proactive Protection for Your Software Supply Chain.Learn More
Socket
Book a DemoInstallSign in
Socket

@cloudflare/util-responsive

Package Overview
Dependencies
Maintainers
37
Versions
592
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cloudflare/util-responsive

Cloudflare Responsive Design Utils

npmnpm
Version
4.0.0
Version published
Weekly downloads
1.7K
13.14%
Maintainers
37
Weekly downloads
 
Created
Source

@cloudflare/util-responsive

Cloudflare Responsive Design Utils

Installation

Installation with yarn is recommended


$ yarn add @cloudflare/util-responsive

Usage

import React from 'react';
import PropTypes from 'prop-types';
import { withAutoWidth } from '../../src';

const FullWidthComp = ({ width }) => (
  <svg width={width} height={100}>
    <rect width={width} height={100} fill="blue" />
  </svg>
);

FullWidthComp.propTypes = {
  width: PropTypes.number.isRequired
};

export default withAutoWidth(FullWidthComp);

FAQs

Package last updated on 08 May 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts