Last week, I spent about 8 hours coding during my free time after work.
Personal Website 🌐
Refactoring:
Instead of three fields:
- text, textEnglish, textGerman
I now have a single field in the code:
- an array text string[].
Finally. I’ve been planning this for a long time. I also considered another option: instead of an array, using a full Hash Map. But in the end, I decided to stick with a simple array because the PostgreSQL driver supports this data type out of the box, whereas saving a Hash Map to the database would have required extra overhead. The structure of the array is controlled via a global variable:
var SupportedLanguages = []language.Tag{language.Russian, language.English, language.German}
Programming without AI 🥴
In one of my previous posts, I mentioned that I intended to write the code for my personal website without using AI. Well, that plan didn’t work out. My persistence only lasted for that one week. The problem is that my free time is very limited since life events constantly pop up. Because of this, I don’t really want to spend hours on manual refactoring. I had two choices:
- Start doing the task manually, but I wouldn’t have been able to finish it by the end of the week 🐌
- Do the refactoring using a local LLM. Write fast, fix fast 🌲
In the end, I chose the second option 😤