1.0.1 • Published 5 years ago

react-3d-rotation-box v1.0.1

Weekly downloads
4
License
MIT
Repository
github
Last release
5 years ago

react-3d-rotation-box

A lightweight react component to enable 3d effect rotation for images, logos or other content.

Demo is here: Demo is here

Usage

npm install -S react-3d-rotation-box
import RotationBox from "react-3d-rotation-box";

<RotationBox>
    {/* any content you want to make 3d rotation effect */}
    <img
        src="https://reactjs.org/logo-og.png"
        style={{ width: "100%" }}
    />
</RotationBox>

You can also customize the depth of 3d rotation by modifying these attributes below:

<RotationBox
    minWidth="800px"
    minHeight="400px"
    perspective="300px"
    rotateForce={10}
>
    {/* any content you want to make 3d rotation effect */}
    <img
        src="https://reactjs.org/logo-og.png"
        style={{ width: "100%" }}
    />
</RotationBox>