svelte: Svelte 5: Incorrect Server Output for `$effect.root`

Describe the bug

On the server, $effect.root should return a noop function, but it returns undefined because the function is immediately invoked.

Reproduction

https://svelte-5-preview.vercel.app/#H4sIAAAAAAAAEz2N0QrDIAxFf0XCHiyM9d21hX3HuodiIwhWRWNhiP_eyGBcyOWE3NwKxjrMoN4V_HYgKHjFCHegb-yQT3SEzDmUpPtmyjrZSMvqV9LBZxLa4eZLFLO4oTGo6ZFCICkHMS-i9jsWzzY82XrsF5Cdp_H_j1uOsFtjcQdFqWD7tAuiqNgToAAAAA==

Logs

No response

System Info

Safari 17.4 iOS

Severity

annoyance

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 15 (11 by maintainers)

Commits related to this issue

Most upvoted comments

can confirm it, behaviour changed in 175. 174 still returns a function