react-surfaces
TypeScript icon, indicating that this package has built-in type declarations

1.1.2 • Public • Published

react-surfaces

A collection of animated background gradients

NPM JavaScript Style Guide

Install

npm install --save react-surfaces

Usage

import React, { Component } from 'react'
 
import Surface from 'react-surfaces'
 
class Example extends Component {
  render() {
    return <Surface 
      variant={2} // defaults to 1possible values: (1-6)
      color1={'#ff0000'} // defaults to #e52421
      color2={'#0000ff'} // defaults to #0000ff
      transitionDuration={'2s'} // optional
      transitionDelay={'0s'} // optional
      transitionTimingFunction={'ease'} // optional
    />
  }
}

License

MIT © sempostma

Package Sidebar

Install

npm i react-surfaces

Weekly Downloads

3

Version

1.1.2

License

MIT

Unpacked Size

102 kB

Total Files

6

Last publish

Collaborators

  • afirus