-
Notifications
You must be signed in to change notification settings - Fork 18
store.subscribe is not a function #58
Comments
I just cloned sveltejs/template, ran Can you please provide more info on your project stack? |
I have |
Top-level usage seems to be OK but hidden complexity could be within |
I have moved to SSR as I was in a hurry but so far this is what I had:
<script>
import { Router, Route } from 'svero';
import Products from './components/Products.svelte';
</script>
<Router>
<Route exact path="/" component={Products} />
</Router>
<script>
import { onMount } from 'svelte';
import { items } from './stores';
let products;
items.subscribe(value => {
products = value;
});
// Fetch products
....
</script>
<div>
{#each products as item}
...
{/each} Nothing complicated here, then while debugging I found that by removing the |
I managed to run your example locally, without issues, also using svelte@3.12.1. How you're integrating your code with svelte-tooling? Probably there's a problem we can't see. 🤔 |
That's weird, I will have to try it our again and digg deep to find the issue. If you guys are having no problem so I may suspect webpack configuration (even tho it doesn't relate that much). What happens exactly is that the |
Hi, @JefferyHus if you want you can try yrv as a drop-in replacement to svero, thank you! |
I'm also having the same issue with even a basic usage with svelte 3.17.1 and Svero 1.0.0 <!-- App.svelte -->
<script>
import {Router, Route} from 'svelte';
</script>
<Router>
<Route path="*">Testing</Route>
</Router> I'm using webpack, could that be causing the issue? |
Svero is now deprecated. Check #68 for alternatives. |
The moment I add this to my
App.svelte
:This error is being thrown:
store.subscribe is not a function
. I have not digg deep to check the source of the problem and tend to ask first if anyone had this before. Otherwise I must be skeptical about the source code of svero.The text was updated successfully, but these errors were encountered: