@cloudflare/util-responsive

3.0.17 • Public • Published

@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);

/@cloudflare/util-responsive/

    Package Sidebar

    Install

    npm i @cloudflare/util-responsive

    Weekly Downloads

    1,250

    Version

    3.0.17

    License

    BSD-3-Clause

    Unpacked Size

    146 kB

    Total Files

    11

    Last publish

    Collaborators

    • lerwincf
    • lbarthonet
    • cf-media-manager
    • jacobbednarz
    • celso
    • cf-radar
    • dash_service_account
    • g4brym
    • snigdha34
    • wrangler-publisher
    • marksteyn
    • chiminator
    • sgoodhew_cf
    • terinjokes
    • third774
    • jsteinberger
    • jasnell
    • asapzacy
    • pcostanzo
    • gregbrimble
    • geelen
    • rexscaria
    • dcruz_cf
    • xuranwang
    • jculvey
    • sejoker
    • vasturiano
    • cf-ci-write
    • segments-write
    • thibmeu
    • xortive
    • gurjinder
    • cf-ci2
    • lvalenta
    • worenga