Skip to content

MapMetrics Flutter SDK

Available

The MapMetrics Flutter SDK is available on pub.dev. API documentation can be found here.

Overview

The MapMetrics Flutter SDK provides a cross-platform solution for integrating MapMetrics Atlas maps into your Flutter applications, supporting both iOS and Android platforms.

Features

  • Cross-platform support (iOS & Android)
  • Interactive map rendering
  • Marker and annotation support
  • Custom styling and themes
  • Gesture controls and camera animations
  • GeoJSON layer support
  • Real-time data visualization

Quick Start

Add the dependency to your pubspec.yaml:

yaml
dependencies:
  mapmetrics: ^0.1.0
dart
import 'package:flutter/material.dart';
import 'package:mapmetrics/mapmetrics.dart';

class MapScreen extends StatefulWidget {
  @override
  _MapScreenState createState() => _MapScreenState();
}

class _MapScreenState extends State<MapScreen> {
  MapMetricsController? mapController;

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: Text('MapMetrics Map')),
      body: MapMetrics(
        styleUrl: 'https://gateway.mapmetrics.org/styles/YOUR_STYLE_ID?token=YOUR_API_KEY',
        onMapCreated: (MapMetricsController controller) {
          mapController = controller;
        },
        initialCameraPosition: CameraPosition(
          target: LatLng(40.7128, -74.0060),
          zoom: 10.0,
        ),
      ),
    );
  }
}

Tutorials

Get started with our step-by-step guides:

Other SDKs

Questions?

If you have specific requirements or questions about Flutter support, please reach out to our team.