Skip to content

[labs/virtualizer] New layoutComplete promise created instead of using existing one #3518

@graynorton

Description

@graynorton

Which package(s) are affected?

Virtualizer (@lit-labs/virtualizer)

Description

When layoutComplete is accessed multiple times for a given layout cycle, the same promise should be returned. It is not.

Reproduction

  1. Run this Playground example

Expected result: Console should log SAME? true
Actual result: Logs SAME? false

Workaround

If you can, avoid accessing layoutComplete multiple times within a given layout cycle

Is this a regression?

No or unsure. This never worked, or I haven't tried before.

Affected versions

1.0.0

Browser/OS/Node environment

Not environment-specific

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    ✅ Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions