Skip to content

Svelte 5: Svelte action does not work with $store as parameter #10514

@ariel-salgado

Description

@ariel-salgado

Describe the bug

In svelte 4 and in version 5.0.0-next.54 i was able to pass $store as action parameter like this.

<div use:action={$store}></div>

But now in version 5.0.0-next.57 this doesn't work

Reproduction

Svelte 4: REPL (Works)
Svelte 5: REPL (Error)

Logs

Error: $store is not defined

message: "$store is not defined"
stack: "ReferenceError: $store is not defined..."

System Info

Svelte REPL

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