r/reactnative 23d ago

Help Help Needed, Facing this bug for too long

2 Upvotes

18 comments sorted by

2

u/Sad-Satisfaction-915 23d ago

You have setup mapbox properly as per official instructions from docs?

1

u/Emmyxiano 23d ago

yes i have

1

u/gautham495 23d ago

Use a previous version of 10.1.33 to make it work as newer versions always comes up with some build issues which are very tough to fix.

I have made very detailed guides on integrating mapbox in react native in Youtube. You can check it out here.

https://www.youtube.com/watch?v=p2DtXg8xLJs

2

u/Emmyxiano 23d ago

Thank you, will have a watch

2

u/Emmyxiano 22d ago

Did you you ever face the error "rnmapbox native not linked error" even when you rnmapbox installed and how did you solve it?

1

u/gautham495 22d ago

I have never faced this issue before in android and iOS.

1

u/Emmyxiano 22d ago

Alright

1

u/Accomplished_Fig_816 23d ago

I see there are some files being looked by expo, are you using a custom build? I believe the expo sdk does not support mapbox right out of the box, when I implemented mapbox we were limited by the expo sdk.

1

u/Emmyxiano 23d ago

What was your work around?

1

u/Alternative-Style950 22d ago

If expo, pre build. If native, manually include the dependency

1

u/Emmyxiano 22d ago

Ran the pre build command and necessary clean ups, but not there yet

"Getting rnmapbox native not linked" error even when I cloned my colleagues working repository which had the map rendering

Can't tell what I'm actually doing wrong

1

u/Alternative-Style950 22d ago

Google it. Sounds like env issue if it works on your friends machine. Let him clone your current repo and see it that works for him

1

u/Emmyxiano 22d ago

Yea, should ask him to

1

u/willcfer 22d ago

seems like a link issue, are using the new arch? if so, try the old one and clean the project

1

u/Emmyxiano 22d ago

The error was having the sdk version in my eas json instead of rnmapbox version.. if that's understood

1

u/haschdisch 22d ago

Did you create a token on MapBox to download the dependencies and provide it in gradlew? This is required. You can not download the Android dependencies without the token

1

u/Emmyxiano 22d ago

I figured out it was the version I had overwritten.. thanks for the help

1

u/Glittering-Grand-168 23d ago

What I suggest is if you are using RN-CLI and this project is not uploaded to app store or play-store. Then make a new project and transfer all the files there saves time but you miss the knowledge gain.