Quantcast
Channel: Ionic Forum - Latest posts
Viewing all articles
Browse latest Browse all 229115

Native google maps custom marker not working on android

$
0
0

Hi all,

I have set a custom marker which works fine on IOS however android doesn't seem to want to know it and instead loads the default.

      let markerOptions: MarkerOptions = {
        position: centre,
        title: 'You are here',
        icon: {
          url : 'assets/img/pin.png'
        }
      };

Not sure if it has something to do with the file path. Also tried to use,

        marker.setIcon({
          'url': 'assets/img/pin.png',
          'size': {
            width: 50,
            height: 50
          }
        });

Which made no difference.

Plus, I tried difference file paths, such as ../assets/img/pin.png but that just breaks the ios app and doesn't fix the android.


Viewing all articles
Browse latest Browse all 229115

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>