Skip to content

Use a single ResizeObserver instance #24

Closed

Description

@ZeeCoder

Seems like it's more performant and the recommended pattern:
WICG/resize-observer#59

Activity

  1. shiba-codes commented on Dec 10, 2019

    @shiba-codes

    Related – #26

  2. ZeeCoder commented on Oct 11, 2020

    @ZeeCoder
    OwnerAuthor

    I'm not convinced yet whether this is an optimisation that's actually worth it or not.
    I've only seen a single benchmark that seem to indicate that it might be better to use a single RO for all hook instances,
    but it wasn't convincing enough to warrant the associated work.

    I'd need a way to test this somehow for myself for a large number of observed elements and measure CPU / memory usage maybe, to see if there's a difference between using one or many RO instances.

  3. ZeeCoder commented on Oct 11, 2020

    @ZeeCoder
    OwnerAuthor

    Or if there was a comprehensive test / article / benchmark that demonstrated that using a single RO instance is significantly better, then I would consider it.

  4. ZeeCoder commented on Nov 13, 2020

    @ZeeCoder
    OwnerAuthor

    I forgot about this one:
    que-etc/resize-observer-polyfill#13 (comment)

    Seems like there's something in there, but I'd still need a way to benchmark CPU + memory usage, so that I could compare a results of the current implementation to one that uses a single instance.

  5. ZeeCoder commented on Nov 13, 2020

    @ZeeCoder
    OwnerAuthor

    I'd really appreciate someone well-versed in benchmarking UI to help out.

  6. Repository owner locked and limited conversation to collaborators on Aug 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions