Static, dynamic | James’ Coffee Blog


Last year, I spent a lot of time iterating on Publish, the publishing interface for my website. This interface is a static HTML page that generates a markdown file. This markdown file can then be published to my website. The Publish page is public, but you cannot publish a blog post unless you have access to my Git repository.

This paradigm works well with my static website. I have a user interface that lets me prepare a post for publishing, and a button I can click that takes me to GitHub where I can publish the page. Having posts in static files and version control is significant to me. Static files are easy for me to reason with. I can see my data without having to use a database.

With that said, I see opportunities to improve the Publish tool that can only be done with a dynamic page.

The main improvement I would like to make is to streamline image publishing.

Right now, that publishing images is presently a multi-stage process. Images need to be manually uploaded to my Git repository, which is not ideal. I also need to manually convert images to webp and avif. Ideally, this would all be done automatically, in the background. This could be done by having a dynamic page that lets me drag-and-drop images. Then, in the back-end, the images could be converted, saved, and then made available on my website.

For a while, I have been thinking about the paradigm of static and dynamic working together. I would like a site that is fundamentally static but also has tools that let me publish content in the way I want. A dynamic tool could be used to generate static files that can then be saved in a Git repository. The Kirby CMS uses a static file backing, where you can use an interface to manage a site and still have a static website in the end.

Having a static site is significant to me because:

  1. Static sites are fast (when engineered with performance in mind, of course!0.
  2. There is a significantly reduced admin tax. If my publishing tool goes down for any reason, my static site can still be available.
  3. I enjoy having folders of text files to edit: both markdown for posts and HTML for templates.

Rather than saying one or the other is better, I think a combination of both static and dynamic would let me get the best of both worlds: the reliability and speed of static sites combined with the user experience offered by a dynamic editor.



Source link

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top