expo / snack

Expo Snack lets you run Expo in the browser.
https://snack.expo.dev
MIT License
370 stars 110 forks source link

Vote My App no longer works since updating Expo Snack in browser #410

Closed Jam777J closed 1 year ago

Jam777J commented 1 year ago

Summary

I was prompted to perform an update on expo snack in my browser recently. Since doing that, I've unable to open the app in expo go, and even the preview devices in the browser in expo snack. Does anyone know the cause of this or how to fix it?

Note: Everytime I try to open the app, it's stuck on the snack loading screen. Sometimes, the words "loading..." OR "Updating..." also appears on this permanent loading screen. stuck-loading-screen

What platform(s) does this occur on?

Android, iOS

SDK Version

v46.0.0

Reproducible demo or steps to reproduce from a blank project

Jam777J commented 1 year ago

I'm new to using the forums here, if this issue should be under a different section, please feel free to let me know. Thanks in advance for any help

Kudo commented 1 year ago

hi @Jam777J! does it work if you change to sdk 47?

Jam777J commented 1 year ago

I get more errors when I switch to SDK 47. Especially errors like a.map and errors appear.

Kudo commented 1 year ago

the connection issue is resolved on sdk 46. the a.map issue on sdk 47 is real, so it's happening on sdk 46 now as well. for what i understand, you may need to apply the patch to HomeScreen.js

         {origin && destination && (
           <MapViewDirections
             origin={origin}
             destination={destination}
-            waypoints={waypoint}
+            waypoints={[waypoint]}
             apikey={googleAPI}
             mode="DRIVING"
             strokeWidth={3}
             strokeColor="purple"
           />
         )

there are other problems in your snack project. that is not related to the connection issue.

Jam777J commented 1 year ago

Thanks for the tip, Ill try this and see if the problem persists. What are the other problems you mean?

Kudo commented 1 year ago

for example, the coordinate of <Marker coordinate={{ latitude: destination.latitude, longitude: destination.longitude }}> does not support null latitude and longitude, but you have this code:

  const [destination, setDestination] = React.useState({
    latitude: null, //10.68972,
    longitude: null, //-61.793067,
  });
Jam777J commented 1 year ago

Oh that, that was just something I was trying out. Wasn’t meant to stay there.

Jam777J commented 1 year ago

I just want to say thank you for your help, after applying the "[]", my app is working again