Skip to content
Articles
Article

Making an app's map respect dark mode without running a tile server

by Frank Milvus dev.to

9 min read

A theme-aware map in Flutter sounds like a styling task: pick a tile URL, invert it in dark mode, move on. It is really an ownership task. Four maps in our app — a search result preview, the fullscreen search map, a profile's city card and the fullscreen city map — each carried their own copy of one hardcoded light tile URL. Every other surface went dark correctly, and those four stayed bright, w…

Forum

Questions about this, or something to add?

Discuss on the forum

Topics Maps and location

Report this · Wrote this? Claim it

FlutterX is supported by