Skip to content

Binding a nested writable $store value doesn't workΒ #13914

@0xDjole

Description

@0xDjole

Describe the bug

Binding a nested writable $store value doesn't work with the error saying in the browser that the value is not bindable.

Reproduction

// Parent

<Preview
	bind:contactInfo={$store.contactInfo}
</Preview>

// Preview

Here contactInfo is a property, but it's coming from the store. This breaks my app on 200 places.

let {
    contactInfo = $bindable()
} = $props();

<PhoneNumber
    bind:value={contactInfo.phoneNumber.value}
/>

Logs

bind:value={contactInfo.phoneNumber.value}` (src/lib/reservation/components/Reservation/Preview/Preview/index.svelte:128:5) is binding to a non-reactive property

System Info

Arch linux, google chrome, svelte5 with sveltekit.

Severity

blocking an upgrade

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions