Telerik-Verified-Plugins / Mapbox

Native OpenGL maps for your Cordova app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to add element over map

ansarikhurshid786 opened this issue · comments

Hi,
I want to add current location button and other some user button. How can i add it properly which support android and ios. because i can't see where this map is rendering.

Hi @ansarikhurshid786. Map is rendered inside ios and android code. You can try to fork plugin and add yourself into ios and android code required button.

I want to use it because it give best user experience. Presently I am using mailbox-gl-js which is really bad user experience in ionic 3 android and iOS application.

I don't have that much experience to fork and add my own. can you help me add button over map and how to load map in specific html element id.

how to load map in specific html element id

I can't since it requires lots of work and time. You can look at @dagatsoin branch. In my experience mapbox-gl-js has some problems with old browsers and it's performance is not that good. Maybe it's better to use just leaflet+mapbox tiles

Yes, mailbox-gl-js not good performance in mobile application. Should I use this plugin or not

Should I use this plugin or not

Well it's up to you to decide. But I don't think that adding elements over map will be ready soon.
Regarding mapbox-gl-js instead of it just use leaflet+mapbox tiles it won't require many changes in your code and you will get good performance. The only problem-it won't work offline,

ok thanks. just tell me leaflet + mapbox will support 3d also. if you have link for leaflet + mapbox can you please send me.

No it won't. Leaflet just for 2D.

Oh but I want 3d also. Anyway thanks a lot for giving me your valuable time.

@risinghero how to use leaflet+mapbox? can you give me any reference please

Hi, @ansarikhurshid786 . Here is example
But I think that you can add button into this plugin by yourself - just fork it, add button into android and iOS code and add events

Ok thanks I will check. You mean leflet right. I think leflet base on mapbox, am I right?

Yes, Leaflet is much faster than mapbox gl js. Thanks a lot @risinghero