Skip to content
This repository was archived by the owner on Jun 21, 2023. It is now read-only.
This repository was archived by the owner on Jun 21, 2023. It is now read-only.

JS Benchmark - Keyed Version #63

@davidbwaters

Description

@davidbwaters

Hey. I noticed simulacra is listed as 'non-keyed' in the benchmarks test by JS Performance Benchmarks. They define the classification:

Keyed implementations create an association between the domain data and a dom element by assigning a ‘key’. If data changes the dom element with that key will be updated. This feature might be necessary when integrating with 3rd-party libraries, transitions or when the DOM keeps some state. Non-keyed implementations are free to reuse the existing dom nodes in whatever way they like and thus might be faster, but may cause issues if there’s a dependency on the particular dom nodes.

Here is an overview of the classification and potential problems.

This is out of my scope, but if I am understanding correctly from the readme section on safety-checks, simulacra is keyed by default. The benchmark includes a test that is supposed to check if a library is keyed or not, which I'm assuming classified simulacra as non-keyed.

If simulacra is keyed or can be configured to be, I'd like to see how performance is effected. It scores very high in the current test, as it stands.

Is simulacra keyed by their standards described above? If not, is there a reason why safety checks to prevent the potential problems tracking DOM nodes mentioned were not included or shouldn't be added? Thanks.

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