@coorpacademy/react-native-confetti-cannon
v1.1.3
Published
Fork: React Native confetti explosion and fall like iOS does.
Downloads
11
Readme
Installation
npm install react-native-confetti-cannon
# or
yarn add react-native-confetti-cannon
Usage
import ConfettiCannon from 'react-native-confetti-cannon';
const MyComponent = () => (
<ConfettiCannon count={200} origin={{x: -10, y: 0}} />
);
Props
| Name | Type | Description | Required | Default | |----------------|------------------------|--------------------------------------------|----------|----------------| | count | number | items count to display | required | | | origin | {x: number, y: number} | animation position origin | required | | | explosionSpeed | number | explosion duration (ms) from origin to top | | 350 | | fallSpeed | number | fall duration (ms) from top to bottom | | 3000 | | fadeOut | boolean | make the confettis disappear at the end | | false | | colors | Array | give your own colors to the confettis | | default colors |