Replies: 2 comments 4 replies
-
Here's a comment that might help explain: #269 (comment) |
Beta Was this translation helpful? Give feedback.
1 reply
-
I'd maybe take a step back and consider why have all this complexity just to allow the data to be passed in using child components via a slot (where the child components don't actually render anything) instead of simply passing an array as a prop to the parent? It would achieve the same thing in a far simpler, more efficient way, and sidestep the SSR issue you are experiencing. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I can't find the right combination of things to allow a store to be updated on the server-side.
I have 2 components.
Parent.svelte
Child.svelte
then somewhere in my app
this works, but list items only show up on the client-side, the
ul
is empty in the HTML sent from the server.it works perfectly fine when the store is defined in a
<script context="module">
, but then it is shared across all instances of myparent
component, which I don't want.Is there a way of communicating between components in an easy way that works on the server?
EDIT: I built this following the mapbox example, if there's a better way of doing things like this, please let me know.
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions