Skip to content

Support arrays of objects as state #9

@reZach

Description

@reZach

Can this library support arrays as a state? ie.

[
    {
        name: "A",
        height: 4,
        data: {
            // ...
        }
    },
    {
        name: "B",
        height: 8
        data: {
            // ...
        }
    },
]

You mention in the docs that

the deep-diff library calculates structural changes between two javascript objects. As such, your state must be a diffable object.

Instead of just diffing each side, could you iterate over all elements in an array and store the diffs of that?

I found your repo looking at this list, and realized that I'm essentially building your library here and figured it doesn't hurt to ask 😄.

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