Skip to content

Create reusable image fetching logic for other standards #4474

Open

Description

@domenic

Ported from https://www.w3.org/Bugs/Public/show_bug.cgi?id=24055. Standards like Notifications or Web App Manifest need to fetch images. It's unclear which portions of <img>'s very-complicated processing model they should involve, but in that bug people seem to be advocating for at least MIME sniffing and the "list of available images" cache.

This also impacts <input type="image">, and probably <link rel="icon">.

The thread is long and someone planning to tackle this should probably read through it and distill it here before going too far.

Note: #1643 is probably a prerequisite for this issue.

Activity

  1. annevk commented on Feb 4, 2020

    @annevk
    Member

    This is also needed for CSS background-image et al. All fetching of images should share the same pipeline.

  2. annevk commented on Oct 26, 2020

    @annevk
    Member

    See also w3c/csswg-drafts#5173 and various issues linked from there.

  3. zcorpan commented on Oct 29, 2020

    @zcorpan
    Member

    This was discussed a few days ago in the WHATWG TPAC breakout session. Minutes at https://www.w3.org/2020/10/26-whatwg-minutes.html#fetching (cc @emilio )

    zcorpan: old issue. Browsers are probably reusing image loading logic for many things, but HTML Standard only specifies special logic for <img>. This makes adding new image-loading features, e.g. to CSS, hard. No work in the last 7 years to my knowledge. Any progress on solving this, or new information on how to solve?

    emilio: interop issues with CSS images having different caching policies. But usually all browsers have a centralized image loader. Shared caches, and so on.

    zcorpan: also an issue with the image cache. Probably doesn't match implementations.

    emilio: changed Gecko to match spec a bit better for image cache. This can also affect preloading.

    Domenic: interest from chromium to work on memory cache, image cache..

    emilio: arch in gecko is different from chromium. if you have an uncachable image loaded from a stylesheet, (something something)

    Domenic: interop issue is important. emilio you seem to have knowledge about this

    emilio: happy to work on this

    <annevk> And with EXIF there’s decoding considerations too that need centralization (And I guess in general we want uniform image decoders across features that consume images.)

    Domenic: I'll take the action item to start the discussion to collate the concrete interop issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions