React Here Maps

React Here Maps

  • Docs
  • API
  • Help
  • GitHub

›API Reference

Introduction

  • Installation

API Reference

  • <HEREMap />
  • <Marker />
  • <RouteLine />
  • <Circle />
  • usePlatform()

<Marker />

<Marker /> is the component used for displaying a marker on the map, the only required props are lat and lng to set its position.

Usage

import { HEREMap, Marker } from 'here-maps-react';

export function Map() {
  return (
    <HEREMap
      appId="my_app_id"
      appCode="my_app_code"
      center={{ lat: 10.998666, lng: -63.79841 }}
      zoom={12}
    >
      <Marker
        lat={10.998666}
        lng={-63.79841}
        draggable
        onDragEnd={e => {...}}
      />
     </HEREMap>
  );
}

Props

Available

  • lat: H.geo.Latitude;
  • lng: H.geo.Longitude;
  • bitmap?: string;
  • children: React.ReactNode
  • draggable?: boolean;
  • onPointerDown?: (e: H.util.Event) => void;
  • onPointerUp?: (e: H.util.Event) => void;
  • onPointerMove?: (e: H.util.Event) => void;
  • onPointerEnter?: (e: H.util.Event) => void;
  • onPointerLeave?: (e: H.util.Event) => void;
  • onPointerCancel?: (e: H.util.Event) => void;
  • onDragStart?: (e: H.util.Event) => void;
  • onDrag?: (e: H.util.Event) => void;
  • onDragEnd?: (e: H.util.Event) => void;
  • onTap?: (e: H.util.Event) => void;
  • onDoubleTap?: (e: H.util.Event) => void;
  • onLongPress?: (e: H.util.Event) => void;

To be implemented

  • alt?: H.geo.Altitude;
  • ctx?: H.geo.AltitudeContext;
  • min?: number;
  • max?: number;
  • visibility?: boolean;
  • zIndex?: number;
  • provider?: H.map.provider.Provider;
  • icon?: H.map.Icon;
  • data?: any;

Reference

You can find more info about this types here.

Last updated on 8/15/2019 by Gustavo Ordaz
← <HEREMap /><RouteLine /> →
  • Usage
    • Props
    • Reference
React Here Maps
Docs
Getting Started
Community
Twitter
More
GitHubStar
Copyright © 2021 ordazgustavo