Cannot access ‘variable_name’ before initialization – Svelte Error
Svelte throws the error, Cannot access ‘variable_name’ before initialization, when we try to assign reactive variables declared using $: to non-reactive variables like const, var, let etc. Consider this example…