-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Description
Describe the bug
The particular pattern below of lazily loading components fails, telling me that the lazily loaded component variable is not a function. This works in v4 and worked in previous versions of v5 (although I haven't checked when exactly it broke).
Reproduction
Interestingly, this works: https://svelte-5-preview.vercel.app/#H4sIAAAAAAAACpWRy2rEMAxFf0V1F5PAkOyTTGDodv6gKcX1o5g6tomVltTk32vXzAMmFLqUdHQlXQUilRaeNM-BGDoK0pCjc2RPcHEp8J9Co4ixt_PEUqbzbFIO-8EMqAUCV95purwyOzprhEE4gKTai_ZMnOi30svJUi7405mK1a6-SpnwqCQ83ImtSaR7mxGtAWsaphX7OATqF8OgKOHQQ0jIgMwab7WotH0vNieWbQY3i3Hpgn5RhaBiZkIodlV9S1bZiV1ZVlxIOmts_zl3yyic5uzTuvapDS5dXZ2PjuaERkQ7sxPby9eJqpWMTHzVaLmSSnDSJPl1f_nsbfOfL3Z9RkH_ssCuW7n-fsLL-gOK5_fWRwIAAA== - works, so it has something to do with the order that stuff is in the template it looks like.
Logs
Uncaught TypeError: LazilyLoadedComponent is not a function
in App.svelte
App playground:output:2662
consequent_effect playground:output:2556
update_reaction playground:output:1229
update_effect playground:output:1401
create_effect playground:output:407
branch playground:output:539
if_block playground:output:2556
update_reaction playground:output:1229
update_effect playground:output:1401
process_effects playground:output:1562
flush_queued_root_effects playground:output:1450
process_deferred playground:output:1498
App playground:output:2662
consequent_effect playground:output:2556
update_reaction playground:output:1229
update_effect playground:output:1401
create_effect playground:output:407
branch playground:output:539
if_block playground:output:2556
update_reaction playground:output:1229
update_effect playground:output:1401
process_effects playground:output:1562
flush_queued_root_effects playground:output:1450
process_deferred playground:output:1498System Info
REPLSeverity
annoyance