You're Invited: Meet the Socket team at BSidesSF and RSAC - April 27 - May 1.RSVP
Socket
Sign inDemoInstall
Socket

maplibre-gl-js-amplify

Package Overview
Dependencies
Maintainers
3
Versions
102
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

maplibre-gl-js-amplify

MapLibre Plugin to Support Amplify Geo Integration

1.1.0
Source
npm
Version published
Weekly downloads
27K
2.24%
Maintainers
3
Weekly downloads
 
Created
Source

Maplibre GL JS Amplify

A plugin for maplibre-gl-js for integration with Amplify Geo.

Reporting Bugs/Feature Requests

Open Bugs Feature Requests Closed Issues

Usage

yarn add maplibre-gl-js-amplify

Using AmplifyMapLibreRequest to Display a Map

import { createMap } from "maplibre-gl-js-amplify";
import Amplify from "aws-amplify";
import awsconfig from './aws-exports';

Amplify.configure(awsconfig);
...
  const map = await createMap({
        container: "map", // An HTML Element or HTML element ID to render the map in https://maplibre.org/maplibre-gl-js-docs/api/map/
        center: [-123.1187, 49.2819],
        zoom: 11,
        region: "us-west-2"
  })

Using AmplifyGeocoderAPI with maplibre-gl-geocoder

import Amplify from "aws-amplify";
import { AmplifyGeocoderAPI } from "maplibre-gl-js-amplify";
import awsconfig from './aws-exports';
import maplibregl from "maplibre-gl";
import MaplibreGeocoder from "@maplibre/maplibre-gl-geocoder";
import "@maplibre/maplibre-gl-geocoder/dist/maplibre-gl-geocoder.css";

Amplify.configure(awsconfig);
...
  const geocoder = new MaplibreGeocoder(AmplifyGeocoderAPI, {
    maplibregl: maplibregl,
  });
  map.addControl(geocoder);

Deeper dive

API Documentation

See API.md for complete reference.

Examples

See FIXME.

Contributing

See CONTRIBUTING.md.

Keywords

Amplify

FAQs

Package last updated on 09 Sep 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts