react-native-circular-slider-example icon indicating copy to clipboard operation
react-native-circular-slider-example copied to clipboard

Example crashed on Android

Open nhatquya opened this issue 8 years ago • 5 comments

I've implement your code and app crashed on Android. I solved this problem by wrap <Svg/> component with <View/> component and every things working well for me. Could you please check my gist: https://gist.github.com/nhatquya/ab2002b7ab1d578004834e7854aecfb3 Thanks!

nhatquya avatar Dec 22 '16 07:12 nhatquya

Interesting, thanks.

When you say the app crashed ... I guess you mean a "red-box" right? do you have a stack-trace?

I wasn't seeing crashes on either platform last time I ran this (it was a while ago) ... did you change anything else e.g. the React-Native version or the react-native-svg version?

steveliles avatar Dec 22 '16 09:12 steveliles

My app crashed on Android: RN: v0.39.2 react-native-svg: v4.4.1 ART: v 0.10.1

The app crashed with the "Unfortunately, MyApp has stopped" alert. it's not the React Native Red Screen.

nhatquya avatar Dec 22 '16 09:12 nhatquya

Aha, so newer React-Native and react-native-svg than I was using. Possibly you've come across a bug in the newer version of react-native-svg? (because using panhandlers on a Circle is supposed to work - and did work in the earlier version).

Moving the panhandlers to an enclosing view presumably changes the behaviour somewhat - e.g. in my version you had to be touching the circle at the end of the slider to be able to drag it, but in yours I guess you can touch anywhere - depends if that's the behaviour you want to achieve i guess.

steveliles avatar Dec 22 '16 09:12 steveliles

I don't know what happen on my side and i got what you mean. I trying make feature same as your example but facing some problem with panresonder on <Circle/>. Please keep this issues until I investigate the root cause. Thanks!

nhatquya avatar Dec 22 '16 09:12 nhatquya

sure - thx, good luck!

steveliles avatar Dec 22 '16 09:12 steveliles