sveltejs / sveltejs/kit

Server data not reactive anymore in runes mode

Open
#12,568 1 comment 8 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

svelte 5
Dominant language
JavaScript
Stars
20.8k
Forks
2.3k
Avg merge
1d 16h
Merged PRs (30d)
156

Description

Describe the bug

In runes mode

let {data} = $props()

returns data which is not bindable to eg. input elements etc.
afaik this worked before and its also working when using 'let mode'

Reproduction
import type { PageServerLoad } from './$types';

export const load = (async ({params}) => {
    return {name: params.name};
}) satisfies PageServerLoad;
<script lang="ts">
    let {data} = $props()

</script>

<p>{data.name}</p>
<input type="text" bind:value={data.name} />
Logs

No response

System Info
I dont get output since I'm using pnpm, help appreciated
Severity

annoyance

Additional Information

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the provided runes-mode reproduction using $props(), PageServerLoad, and bind:value, then compare it with the reported working 'let mode'. Confirm the expected behavior by checking whether data.name remains reactive and bindable; done means the reproduction works as described in runes mode.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, typescript
Domain
frontend, web-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.