mapbox / mapbox/leaflet-image

Unable to export .mbtiles layer

Open
#93 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
380
Forks
140
PR merge metrics
No merged PRs in 30d

Description

Hi,

I'm rendering a .mbtiles background as tile layer on my map using [this library](https://gitlab.com/IvanSanchez/Leaflet.TileLayer.MBTiles). I try to export my map using leaflet-image but I get a white background. I don't understand what is the problem since my layer supports CORS.

The only difference I spot when I inspect the rendered map, is that my tiles are blobs. Is it the problem ?

**OSM Layer (export is working) :**
![leafletbackground](https://cloud.githubusercontent.com/assets/6130521/22415479/175486b2-e6c8-11e6-9325-097063c317f2.jpg)

**MBTILES Layer (export not rendering background):**
![mbtiles](https://cloud.githubusercontent.com/assets/6130521/22415480/17587d08-e6c8-11e6-9e08-da88c8bd45e8.jpg)

Thanks

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the export with the Leaflet.TileLayer.MBTiles layer used in the report, then compare it with the working OSM layer. Trace how leaflet-image handles tile images and blob-backed tiles; done means the MBTiles background appears in the exported image.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.