View on GitHub

openui5-googlemaps

Google Maps library for OpenUI5

Download this project as a .zip file Download this project as a tar.gz file

Getting Started

Include the openui5.googlemaps library

sap.ui.getCore().loadLibrary("openui5.googlemaps", "../openui5/googlemaps/");

Example - render a map with a marker

<?xml version="1.0" encoding="UTF-8" ?>
<mvc:View xmlns:mvc="sap.ui.core.mvc"
    xmlns:gmaps="openui5.googlemaps"
    controllerName="sampleController">
    <gmaps:Map height="250px" zoom="12" lat="-33.895" lng="151.275" 
     apiKey="AIzaSyDY0kkJiTPVd2U7aTOAwhc9ySH6oHxOIYM">
        <gmaps:markers>
            <gmaps:Marker lat="-33.895" lng="151.275" info="Bondi Beach" />
        </gmaps:markers>
    </gmaps:Map>
</mvc:View>