Skip to content

Request for MapWritableState nested object access. #634

Open
@davidboom95

Description

@davidboom95

What problem is this solving

Modifying deeply nested properties in the state.

Proposed solution

// Object
...mapWritableState(useStore, {
     myCity: 'form.address.city',
})

// Array ( outputs the latest key as the variable name, in this case city)
...mapWritableState(useStore, ['form.address.city'])

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    💬 In discussion

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions