Auto Scale Content To Fit Inside The Viewport

Category: Others , React
Author:pomber
Views Total:7 views
Official Page:Go to website
Publish Date:September 3, 2020
License:MIT

A React component that automatically scales the content to fit it within the viewport. Works with server-side rendering.

Install & Import:

# NPM
$ npm i react-fit-to-viewport --save

# Bower
$ bower install react-fit-to-viewport --save

Basic Usage:

<FitToViewport width={600} height={450} minZoom={0} maxZoom={1}>
  {stuff}
</FitToViewport>

Preview:

Auto Scale Content To Fit Inside The Viewport

You Might Be Interested In:

Leave a Reply