title: Use Supabase .select with Sveltekit store
body: <p>if in my current .svelte file i have</p>
  <pre><code>let todos = [];
  
  onMount(async () =&gt; {
  let { data, error } = await supabase .from('todos') .select('*')
  todos = data;
  
  </code></pre>
  <p>however i don't think that's pretty efficient,</p>
  <p>in my store.js file, should it be written as</p>
  <pre><code>export const todos = writable([])
  
  export const loadTodos = async() =&gt; {
  let { data, error } = await supabase
  .from('todos')
  .select('*')
  todos = data;
  }
  </code></pre>
  <p>Im not sure if that is even correct but, If so, how do i call it back into my .svelte file to load ?</p>