Close Menu
  • Home
  • AI
  • Big Data
  • Cloud Computing
  • iOS Development
  • IoT
  • IT/ Cybersecurity
  • Tech
    • Nanotechnology
    • Green Technology
    • Apple
    • Software Development
    • Software Engineering

Subscribe to Updates

Get the latest technology news from Bigteetechhub about IT, Cybersecurity and Big Data.

    What's Hot

    Announcing Amazon EC2 G7e instances accelerated by NVIDIA RTX PRO 6000 Blackwell Server Edition GPUs

    January 25, 2026

    Tech CEOs boast and bicker about AI at Davos

    January 25, 2026

    How Content Management Is Transforming Construction ERP

    January 25, 2026
    Facebook X (Twitter) Instagram
    Facebook X (Twitter) Instagram
    Big Tee Tech Hub
    • Home
    • AI
    • Big Data
    • Cloud Computing
    • iOS Development
    • IoT
    • IT/ Cybersecurity
    • Tech
      • Nanotechnology
      • Green Technology
      • Apple
      • Software Development
      • Software Engineering
    Big Tee Tech Hub
    Home»iOS Development»Leaflet marker icons intermittently disappear (shown as “?”) in WKWebView on iOS, even with data-URI icons
    iOS Development

    Leaflet marker icons intermittently disappear (shown as “?”) in WKWebView on iOS, even with data-URI icons

    big tee tech hubBy big tee tech hubJanuary 8, 2026012 Mins Read
    Share Facebook Twitter Pinterest Copy Link LinkedIn Tumblr Email Telegram WhatsApp
    Follow Us
    Google News Flipboard
    Leaflet marker icons intermittently disappear (shown as “?”) in WKWebView on iOS, even with data-URI icons
    Share
    Facebook Twitter LinkedIn Pinterest Email Copy Link


    Context

    I’m embedding a Leaflet map inside an iOS app using WKWebView (BeeWare/Toga, but this seems WebView-level rather than framework-specific).

    Problem

    Leaflet’s default marker icon and shadow intermittently disappear and are rendered as ? placeholders.

    This happens:

    • After the app has been backgrounded and resumed (warm start).

    • Occasionally even on first/cold start.

    • With no console errors.

    • With no network requests involved (icons are inlined, but the issue remains).

    The map itself works. Tiles load correctly. Only the marker icon and shadow sometimes disappear.

    Setup details

    • Leaflet (standard build).

    • The map runs in a local HTML file loaded into a WKWebView.

    • Icons are inlined as base64 PNG data-URIs, not fetched from disk or network.

    • No relative paths are used for marker assets.

    Example (simplified):

    // Executed before map creation
    L.Icon.Default.mergeOptions({
      iconUrl: 'data:image/png;base64,...',
      iconRetinaUrl: 'data:image/png;base64,...',
      shadowUrl: 'data:image/png;base64,...',
    });
    
    // Later
    L.marker([lat, lng]).addTo(map);
    

    Despite this, the marker sometimes renders as a ? glyph instead of the image.

    Observations

    • When it fails, both icon and shadow disappear.

    • There is no tileerror, image error, or JavaScript exception.

    • A new cold start seems to fix the issue.

    • This feels like a WebKit / WKWebView lifecycle or memory issue, not a Leaflet path issue.

    What I think I have ruled out

    Even with fully inlined assets and correct ordering, the issue persists sporadically.

    Question

    Has anyone encountered Leaflet marker icons disappearing in WKWebView, especially on iOS, even when using data-URI icons?

    Specifically:

    1. Is this a known WKWebView image lifecycle or memory purge issue?

    2. Is there a canonical way to make Leaflet marker icons robust across background/foreground transitions?

    3. Is explicitly hosting marker PNGs over HTTPS actually more reliable than inlined assets in this environment?

    4. Are there WebKit bugs or recommended patterns for keeping image-backed DOM elements alive across app suspension?

    I would greatly appreciate insight into why this happens and what the most stable, review-safe solution is on iOS.



    Source link

    dataURI disappear icons intermittently iOS Leaflet Marker shown WKWebView
    Follow on Google News Follow on Flipboard
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email Copy Link
    tonirufai
    big tee tech hub
    • Website

    Related Posts

    ios – Why does my page scroll up when I tap on a button?

    January 25, 2026

    swift – iOS suspends app after BLE discovery even though I start Always-authorized location udpates

    January 24, 2026

    ios – ASAuthorizationControllerDelegate always returns .canceled for Face ID passcode fallback and failed attempts

    January 23, 2026
    Add A Comment
    Leave A Reply Cancel Reply

    Editors Picks

    Announcing Amazon EC2 G7e instances accelerated by NVIDIA RTX PRO 6000 Blackwell Server Edition GPUs

    January 25, 2026

    Tech CEOs boast and bicker about AI at Davos

    January 25, 2026

    How Content Management Is Transforming Construction ERP

    January 25, 2026

    This week in AI updates: GitHub Copilot SDK, Claude’s new constitution, and more (January 23, 2026)

    January 25, 2026
    About Us
    About Us

    Welcome To big tee tech hub. Big tee tech hub is a Professional seo tools Platform. Here we will provide you only interesting content, which you will like very much. We’re dedicated to providing you the best of seo tools, with a focus on dependability and tools. We’re working to turn our passion for seo tools into a booming online website. We hope you enjoy our seo tools as much as we enjoy offering them to you.

    Don't Miss!

    Announcing Amazon EC2 G7e instances accelerated by NVIDIA RTX PRO 6000 Blackwell Server Edition GPUs

    January 25, 2026

    Tech CEOs boast and bicker about AI at Davos

    January 25, 2026

    Subscribe to Updates

    Get the latest technology news from Bigteetechhub about IT, Cybersecurity and Big Data.

      • About Us
      • Contact Us
      • Disclaimer
      • Privacy Policy
      • Terms and Conditions
      © 2026 bigteetechhub.All Right Reserved

      Type above and press Enter to search. Press Esc to cancel.