web-ridge / react-native-paper-dates

Smooth and fast cross platform Material Design date and time picker for React Native Paper
https://www.reactnativepaperdates.com
MIT License
663 stars 170 forks source link

Can't find variable: Intl #198

Closed realmhamdy closed 2 years ago

realmhamdy commented 2 years ago

I have a basic use case here, nothing fancy. Here's a snack that shows the problem (click the button to open the modal). It works fine on the Web tab. It doesn't work on Android emulator though. I even installed Intl package in package.json.

swordensen commented 2 years ago

I had this issue as well but, I was able to follow the android caveats guide on the readme.md file.

https://github.com/web-ridge/react-native-paper-dates#android-caveats

realmhamdy commented 2 years ago

@Mikkal24 Can you elaborate on how you fixed that exactly? I enabled Hermes locally (in an expo project) using jsEngine: "hermes" in app.json and now I'm getting a different error: Can't read property 'mediem' of undefined.

RichardLindhout commented 2 years ago

enableHermes and upgrade RN to at least specified version what version of expo are you using?

realmhamdy commented 2 years ago

expo ~46.0.9 RN 0.69.5

realmhamdy commented 2 years ago

Maybe worth noting that I'm using the latest and greatest react-native-paper@5.0.0-rc.5. Dropping that to the lesser 4.x seems to have fixed the problem for me. I planned around using SegmentedButtons though so that's a bummer.

swordensen commented 2 years ago

@realmhamdy sorry im a bit late on the reply but, I also got that error. I think the issue is simply that react native paper dates doesnt support Material Design 3 (Material You) yet.

I am only inferring this because using version 2 works for me. See my comment here:

https://github.com/web-ridge/react-native-paper-dates/issues/189#issuecomment-1243025636