Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It's a variant on that pattern.

The key idea here is that your server-side stuff is completely read-only - so comment systems aren't supported - because the server-side data is treated as a deployment asset.

Have you used platforms like Vercel? Their one big limitation is that you can't use persistent storage with them - if you want to talk to a database of some sort you need to add an extra database vendor.

The baked data pattern works around that by bundling read-only data (usually a SQLite file) with your deployment.



Oh ok so you still have a "dynamic" site that is database driven, but that database is read-only and stored in a pre-generated sqlite file that is deployed with the rest of the site assets?

I don't want to piss on your parade here - perhaps I just don't get this pattern - but isn't this all of the downsides of a dynamic site but without any of the benefits? You are still running slow server side stuff that relies on doing per-request database stuff and all the complexity and security headaches that go along with it (upgrading PHP or Wordpress or whatever), but with none of the benefits of server side functionality and databases (i.e. it is all read-only).


I talk about the benefits of the approach in quite some detail here: https://simonwillison.net/2021/Jul/28/baked-data/#benefits-o... - does that help clarify?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: