SolidJSS
SolidJSโ€ข3y agoโ€ข
1 reply
Delvis

Prpc and Suspense question

const Stats: ParentComponent = () => {
  const allStatsPersonal = allStats({ value: "all" });

  return (
    <Suspense fallback={<div>Loading</div>}>
        <ErrorBoundary fallback={(err) => err}>
        <Show
          when={allStatsPersonal.data}
          fallback={<div>loading</div>}
        >....
            </Show>
    </ErrorBoundary>
      </Suspense>
  );


My understanding was that I wouldnt need the Show component at all, when using prpc with suspense. However CSR works but SSR doesnt work unless I have Show component. I also have to remove fallback from Show component, since it causes hydration key issue.
Was this page helpful?