SolidJSS
SolidJS15mo ago
3 replies
Luka

Server Side Rendering

So I started learning solidjs/solidstart around 3 months ago and instantly after 1-2 weeks I basically started building a project thinking I would learn more which actually is an easier way to learn for me. I've written some code but I don't really know if it is Server Side Rendered or not I want it to be SSR I am going to include some code here

// I have some imports up as well didn't want to include it const user = createAsync(() => get_xelosani(props.params.id)) // - Some javascript here - <MetaProvider> <Title>{user()?.firstname + " " + user()?.lastname}</Title> // more code down here

This is my config file
export default defineConfig({ optimizeDeps: { exclude: ['js-big-decimal'] }, vite({ router }) { if (router === "server") { return { server: { port: 3000, }, }; } else if (router === "client") { } else if (router === "server-function") { } return { plugins: [] }; }, ssr: true });

So based on these if anyone could guide me I would be thankful. Also if you guys have some article, video or book links about SSR with solid or without solid please link it to me.
Was this page helpful?