Building a web site from First Principles

The initial version of this site was an attempt to start with a single HTML page and then document the building of a complete blogging system. I wanted to learn more about React, NPM, TypeScript and other web technologies. And I wasn’t getting much out of tutorials that used a lot of boiler-plate code to get things started. I’m a big believer that the best way to understand what’s under the covers is to start by knitting the covers together yourself.

I also wanted to document the mistakes and false trails that a typical project goes down. It’s easy to take something that works and then write up the minimum set of steps that get you to that point. But most of the learning in software development, like most tasks, comes from making decisions, learning what was right and wrong about those decisions, and then moving forward or backward to the “next right thing”. In fact, an alternative name I thought of for this site is my core development tenet, which is “do the next right thing.”

I didn’t get that project to the point where there is an actual blog system. It turns out that documenting every decision takes time, and that in turn takes a lot more energy than I wanted to continue spending before I was able to write in a fully featured blog system. So I took the initial project, moved it into a sub-folder of this site, and installed WordPress.

But I wanted to preserve the initial site, warts and all. So you can read the initial HTML page, which documents the development of the original site, here. The current iteration, which I have yet to check in from my laptop, has things at the point where I have a static data model being passed through my React components to represent the articles, and does a basic rendering of the list of articles. I’m going to keep the project around and may continue to work on it. The thought processes involved are a pretty good indication of some of the stages of learning and mistake correction that any real software project goes through.

So remember: It’s the job of people selling you on a technology to make it look easy. But the “typical” application always has a few “atypical” aspect to it, or you’d already have a pre-packaged solution available for the problem area. Don’t be frustrated when the tutorials don’t give you the exact answer. Instead, figure out the details from the examples, understand the principles, and forge ahead. Do the next right thing. And if that turns out to be wrong and the next right thing is backtracking, then that’s the next right thing. Sometimes moving backwards is moving forwards. Enjoy the process.

Welcome to The Craft Programmer

This site is dedicated to crafty programming. And I’m using multiple different meanings of the word “crafty”.

  • Craft as in “arts and crafts”, as in hobby and recreational programming.
  • Craft in the sense of artistry and skill, versus brute force and poor design.
  • Crafty in the sense of achieving aims by indirect or non-obvious methods.

I’m a professional programmer by day, and I’ve worked in the industry more than 20 years. Odds are that you’ve used software that I’ve worked on. But at night, I prefer to focus on other hobbies, and some of them only tangentially tie in with computer programming.

This blog will focus mostly on my hobby projects, and how various kinds of programming ties in to these hobbies. Items on the top of my current project list include:

  • I really enjoy making noise with analog synthesizers. I’m hoping to move from playing with them to building them.
  • I’m a fan of slot car racing. Scalextric has recently recently their Arc Pro digital slot car set. I’m interested in figuring out how that works, and looking at new ways to play with the set. Can we get smart automated cars, remote racing, or dream of something new?
  • I also enjoy playing board and role-playing games. There’s an interesting set of changes in the industry lately, with computers playing a role at the table more than ever before.
  • I’m also interested in learning new programming technologies. However, I prefer learning the basics and working up, rather than starting with large templates and boilerplate code I don’t understand.

What you’ll find here will typically be approaching a problem from first principles. I want to document both the successes and the failures of these projects. Knowing what doesn’t work is as important as knowing what does. Especially as tasks grow more complicated, having a good grounding in the fundamentals allows you to better deal with a changing landscape. And that means more fun.

Welcome.