2 ms·
I was about to make a site just like you describe, having a static website that uses js to dynamically show and edit some content and have it be fetched and sto
by Sammi 7y ago
I was about to make a site just like you describe, having a static website that uses js to dynamically show and edit some content and have it be fetched and stored at some serverless host like Firebase. I guess AWS has something similar to Firebase, but the complexity of AWS keeps me away from checking it out.
There are two benefits to my approach, which motivated me to do it.
1. No backend code or database. Not even serverless. All the complexity of managing this is gone. Don't have to worry about quotas or paying for this either as it doesn't exist. We just need a static site host that can pull and host from git. Netlify does this.
2. Perfect caching performance, as we build a new static website when we change any data. Nothing is generated at view time. The thought of each user calling a backend for the same data over and over on each page load, when the page hasn't changed gives me pain. With this all the data is just built directly into the static site and the static site host and the browser takes care of doing http caching if it isn't changed.