10000 Feedback: About "sizes" prop · Issue #11 · andrelandgraf/openimg · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Feedback: About "sizes" prop #11
Open
@NicolasCharpentier

Description

@NicolasCharpentier

Hi, just read your code, went through the same adventure as you writing an optimization endpoint and a image component for a painting gallery website (but going less further) so I want to give you a feedback from my thoughts, take it as is.

By reading your component I see that :

  • the sizes prop can be overwritten for the picture.img by the developer.
  • the sizes prop can not be overwritten for the picture.source by the developer.

So, I am not sure if the overwrite it will be taking into account or not by the browser, I think this should be made sure of.

Plus, having a default sizes of the viewport width looks dangerous to me. I imagine lot of users not knowing about that, then having a browser displaying a full-width image for what would have needed 90px, 200px width, defeating the purpose of the breakpoints. FYI for my site I never used a 100vw size and I always put the sizes prop as mandatory, wanting to think about it each time I use it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0