1.2.1 • Published 2 years ago

react-native-konfetti v1.2.1

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

react-native-confetti

Confetti

Installation

npm install react-native-confetti

Usage

Example

import Confetti from "react-native-confetti";

// ...

    <Confetti animating={true} />

Props


style

Used to style and layout the Confetti. See StyleSheet.js and ViewStylePropTypes.js for more info.

TypeRequired
View.styleNo

colors

Colors to use for confetti

TypeRequired
arrayYes

animating

Bool to start/stop confetti animation. Defaults to false.

TypeRequired
boolNo

duration

Confetti animation duration in milliseconds. Defaults to undefined which means infinite duration.

TypeRequired
numberNo

particlesPerSecond

Number of confetti particles to emit per second. Defaults to 64.

TypeRequired
numberNo

particles

Confetti particles to emit.

Note: Images doesn't appear in Android debug build

TypeRequired
arrayYes

particleLifeSpan

Life time of each particle in milliseconds

TypeRequired
numberNo

TODO

  • Modify speed prop on Android and add velocity on iOS

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT