Skip to content

let $derived object not updating with $bindable #16436

@agrattan0820

Description

@agrattan0820

Describe the bug

Not sure if this is the interaction that's supposed to happen and I'm meant to use the $state in this scenario instead, but I found that when trying to mutate an object defined with let $derived gets passed down to a bound component it doesn't trigger a reactive update to the UI.

As soon as I change it to a $state rune the UI updates so it's simply an annoyance right now keeping us from removing the usage of some $effect runes.

Reproduction

Svelte Playground: https://svelte.dev/playground/114b3ffd135248c481adce41c3366e26?version=5.36.7

Logs

System Info

System:
    OS: macOS 15.5
    CPU: (11) arm64 Apple M3 Pro
    Memory: 251.31 MB / 18.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 22.14.0 - ~/.nvm/versions/node/v22.14.0/bin/node
    Yarn: 1.22.22 - ~/.nvm/versions/node/v22.14.0/bin/yarn
    npm: 10.9.2 - ~/.nvm/versions/node/v22.14.0/bin/npm
    pnpm: 10.12.4 - ~/Library/pnpm/pnpm
    bun: 1.2.18 - ~/.bun/bin/bun
  Browsers:
    Brave Browser: 138.1.80.120
    Safari: 18.5
  npmPackages:
    svelte: ^5.36.6 => 5.36.6

Severity

annoyance

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