react-full-viewport

A React component that sets its children to full viewport.

Usage no npm install needed!

<script type="module">
  import reactFullViewport from 'https://cdn.skypack.dev/react-full-viewport';
</script>

README

react-full-viewport

A React component that sets its children to full viewport.

Installation

$ yarn add react-full-viewport

Usage

<FullViewport>
  {({ toggle, isFull, style }) => (
    <div style={style}>
      <button onClick={toggle}>
        {isFull ? 'Exit' : 'Enter'} full viewport
      </button>
    </div>
  )}
</FullViewport>

License

MIT