Skip to content

Custom icon marker just wont work on IOS #240

Description

@elazarza

Describe the bug
I am trying to show a custom icon marker on the map, tried every possible way. the only way it worked and only on development env and not production, is if I run the capcitor server on https://192.168 and refer the icon url to there like https://192.168.x.x/assets/marker.png

I have tried to put absolutley every possible URL i could think of, eg.
/assets/marker.png
public/assets/marker.png
marker.png
www/assets/marker.png
capacitor://localhost/assets/marker.png
https://localhost/assets/marker.png

even with capacitor's Capacitor.convertFileSrc('')
and all with no luck.
get the same error in xCode - Error Domain=NSURLErrorDomain Code=-1002 "unsupported URL"

what is the correct and for sure working-in-production way of doing that on IOS?

To Reproduce
Steps to reproduce the behavior:
create a marker with icon.url refering to the file you need in the assets folder.

Expected behavior
the png shows instead of google's default pin

Additional context
im using the lastest plugin version with Capacitor 6

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions