Skip to content
pubscout

flutter_map_vector_tiles

2.11.0, released 3 weeks ago by an unverified publisher

Vector tile layer for flutter_map with MapLibre-style rendering and isolate decoding.

WASM-ready
$ flutter pub add flutter_map_vector_tiles
Source repository

What it does

Renders MapLibre and Mapbox GL vector tile styles inside a flutter_map layer. It performs isolate-based tile decoding, GPU-resident raster caching, and screen-space label collision.

AI-written summary of version 2.11.0, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You are building a flutter_map application and need to render vector tiles from MVT sources or PMTiles.
  • You want support for MapLibre styles, sprites, and custom glyph fonts without heavy native dependencies.

Skip it when

  • Your project does not use flutter_map.
  • You need native Google Maps integration rather than OpenStreetMap/vector tile providers.

Strengths

  • Self-contained package handling MVT decoding, style engines, and rasterization.
  • Runs tile decoding on worker isolates and supports multiple platforms including web and desktop.
  • Deterministic LRU memory and disk caching with offline support.

Weaknesses

  • Tied strictly to the flutter_map ecosystem.
  • High concurrent decoding and raster caching can consume significant memory on mobile devices.

Setup

Kind
Flutter widgets
Effort
Low
Code generation
No
Direct dependencies
7

Add flutter_map and flutter_map_vector_tiles to pubspec.yaml and load a style using StyleReader.

import 'package:flutter_map/flutter_map.dart';
import 'package:flutter_map_vector_tiles/flutter_map_vector_tiles.dart' as vt;
import 'package:latlong2/latlong.dart';

final style = await vt.StyleReader(
  uri: 'https://api.maptiler.com/maps/streets-v2/style.json?key={key}',
  apiKey: myKey,
).read();

FlutterMap(
  options: MapOptions(
    initialCenter: style.center ?? const LatLng(48.137, 11.575),
    initialZoom: style.zoom ?? 12,
  ),
  children: [
    vt.VectorTileLayer(
      theme: style.theme,
      tileProviders: style.providers,
      rasterSources: style.rasterSources,
      sprites: style.sprites,
      glyphs: style.glyphs,
    ),
  ],
);

Alternatives

Packages that do the same job and could replace flutter_map_vector_tiles.

Works with

Packages commonly used together with flutter_map_vector_tiles: ones it builds on, ones built on it, and its own family.