Bikeshedding My Templates After Noticing yesterday's Bug
This site for me is a hobby, so I like tweaking things from time to time. It started when I noticed some cruft in the metal section of the pages, and I decided to get rid of it. In the process I worked with an if... then... else because of old habits.
Just after I did that, I remembered that Tera now has a ternary function, which is actually perfect for what I wanted to do in this situation. It’s a lot shorter and cleaner-looking. That should help me a lot with the misplaced endif that I definitely do habitually put in the templates. In the future when the templates are not fresh in my mind, it should help with figuring out what’s going on a lot.
I have actually been wanting to look into that since I first migrated to the new version of Zola. It was in beta then, so I figured it was best to hold off and let things stabilize. There was always the chance of more breaking changes.
This sort of reworking things is a lot of fun to me and very interesting. It gets my brain working on something a little different.
The process of tweaking things can and has given me whole new ideas of how to do something. It’s not always better, but it’s fun to try things out and sometimes break them. Just like anything in life, though, there is always room for improvement. I truly believe that it’s always a good thing to do things differently. As long as I can remember, though, even since I was in elementary school, I have always thought outside the box. There were times when teachers didn’t appreciate that innovative thinking. I can remember thinking they are smart, so they must be right. Now I know better.
I always keep backups when I do this stuff as long as I remember to. I tend to just dive right into new ideas and get burned from shooting myself in the foot from time to time. Plenty of things in programming or scripting make effective footguns.