react-native-confetti-cannon
react-native-confetti-cannon copied to clipboard
Confetti not rendering on top of Images
trafficstars
I am sorry for not having the time to make a minimum reproducible example.
However, I am facing the issue that the Confetti does not render on top of images.
I have attempted to layer the components using zIndex property, but that however does not work.
Can this be somehow solved? In my case it is not rendered over the https://wix.github.io/react-native-ui-lib/docs/components/lists/GridList . Are there any alternatives to this lib?
This has helped me:
<View
style={{
position: "absolute",
top: 0,
left: 0,
right: 0,
bottom: 0,
zIndex: Number.MAX_VALUE,
pointerEvents: "none",
}}
>
<ConfettiCannon
count={200}
origin={{ x: -10, y: 0 }}
fadeOut={true}
autoStart={false}
ref={(ref) => setCannon(ref)}
/>
</View>
(it was suggested by ChatGPT 🤖)
This has helped me:
<View style={{ position: "absolute", top: 0, left: 0, right: 0, bottom: 0, zIndex: Number.MAX_VALUE, pointerEvents: "none", }} > <ConfettiCannon count={200} origin={{ x: -10, y: 0 }} fadeOut={true} autoStart={false} ref={(ref) => setCannon(ref)} /> </View>(it was suggested by ChatGPT 🤖)
it's working bro thank you !