Menu

Why I Switched from SvelteKit SSR to SPA + FastAPI
📰

Why I Switched from SvelteKit SSR to SPA + FastAPI

DEV Community·Tortoise·7 months ago
#P6CdpFvp
#bonus#svelte#fastapi#webdev#backend
Reading 0:00
15s threshold

Originally published at turtledev.io

Hi, I'm Harun , a software engineer who's been building SaaS products for the past few years.

I come from a backend background. To get into frontend development, I tried several frameworks (Angular, Vue, and React) but Svelte was the only framework I could understand just by looking at examples. It clicked immediately. Since then I've been using Svelte for everything including this static blog .

SvelteKit is the natural next step: routing, SSR, full-stack features out of the box. But its default model is SSR, and there's a lot less content out there on using it as a pure SPA. So I went with SSR, same as everyone in the React world goes with Next.js.

Most of my projects also needed AI and ML, which meant a Python backend. So I ended up with two backends: one for SSR, one for the actual logic, both hitting the same database and talking to each other. That got messy fast.

The dev experience wasn't great either:

Pages were slow, especially on Vercel.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.