2 ms·
This website seems simple enough that you could conceivably write the whole thing in plain HTML + vanilla JS, with the quiz data stored as plain JSONs that you
by solardev 4y ago
This website seems simple enough that you could conceivably write the whole thing in plain HTML + vanilla JS, with the quiz data stored as plain JSONs that you either inline or dynamically fetch() as needed. You can do all that with or without a (frontend) web framework, up to you. I don't think you need a relational DB at all, unless there's some hidden feature I didn't see at first glance?
What's the CRUD aspect? If it's just the user login + progress saving, you could probably outsource auth and then store their progress as user-specific metadata, tied to individual question IDs. Doesn't seem like you need much of a backend at all. Maybe a cloud KV store at most (Cloudflare, etc.) or the free plan of some headless CMS.
If you really prefer a relational backend, services like ElephantSQL and Cloudflare D1 and DigitalOcean offer low-costed hosted Postgres that you don't have to maintain yourself (no updates, OS to manage). Instead of a full-blown backend, just write a serverless function that your frontend can talk to which will fetch from the database. But again it's easier (as in lower maintenace) to just use a preexisting solution or headless CMS.
Host your frontend anywhere, like Vercel or Netlify, since it's just static HTML + JS.
TLDR eliminate the backend parts that you don't need, and maintenance becomes a lot simpler. You don't need a backend stack or any other languages except HTML and JS.