The rewrite
Beta users will know all about this, but it's worth telling the public that I started rewriting Fitness Tracker (again) about a month ago. In the end, beta testing confirmed that its ability to securely index photos on their own hard drives and create timelapses off them is the application's real killer feature.
That old adage about assume
When I built the Electron version of Fitness Tracker, I thought a very very small percentage of beta users would use photos and an even smaller percentage of those would generate timelapse videos off them. That made Electron a really good choice - the added velocity from only working with Javascript would get me to release faster. And it did - the Electron version came together very quickly (though I've been using variants of Fitness Tracker for almost seven years so...not that quickly).
And then, I found myself making timelapses. While making timelapses, I learned two very important things:
- when my face gets picked up in timelapses, I look like Pixar badly animated me. Over the years, I've grown to accept that I look like a Toy Story character. In timelapse, let's just say that I didn't make the final cut.
- generating mpeg video isn't a very good fit for Electron.
Rewrite versus rethink
I had some options. The first one that I considered was offloading the timelapse generation feature into Rust. Electron makes this relatively easy. I considered using some css animations to make a splash page that would appear when the browser wasn't able to process updates. I strongly considered that and even implemented it. But Greg-spinner-v1 could most easily be summed up as 'that time that Fitness Tracker turned psychedelic' and I learned a lesson about ambition versus capability.
But in the end, I decided to take the lessons learned and rewrite everything. I made that decision because the entire photo/timelapse feature was totally agile, it was added on as a submodule on goals about 60% through the project. It was the most complicated part of the whole process and every other feature was comparatively easy. I still had a lot of front end work to do and was uncovering all these little backend things I needed. And as I worked more with the front end and hit it harder with Siteimp, I started to find issues with Ant Design.
Those issues started with my questioning my sanity. I was doing some manual testing and was sure that there was a bigger lag when I typed in a modal. That was one of those moments in a development process when you likely just need to go for a long walk, so I did. But when I got back, that lag was even more noticeable. So I wrote a really sketchy Siteimp routine that took way too many screenshots and tested a flow where I typed in a modal and then outside of a modal. Sure enough, it did lag more.
I've been working to boost my design skills which has meant writing a lot of custom scss and trying to reimplement nice things that better designers have built. So I whipped up a modal on my own - it was fully custom and the lag was gone. Suddenly faced with the realization that well, I guess I was going to rewrite the whole front end with something other than Ant Design, it made rewriting everything seem a lot more logical.
And so, I wrote up a waterfall project plan, pulled the trigger and started working with Tauri. It's been incredibly fast and Rust. Rust is honestly a real pleasure to work with on a project like this - a compiler really makes this kind of developing easy. Tauri is great to work with - it has flaws like every other large tool but Tauri itself mostly gets out of the way when I'm building things.
There are certainly things I miss about Electron - the community is huge and for the most part, if you need something someone else has built it before. There are also way more examples of it being used in the wild and when I don't know how to do something, I just find some examples, read them and learn.
And so, the rewrite
This version is noticeably faster - so fast that I've spent part of today slowing down the menu. The final build is noticeably smaller though it's not as complete as the last version (yet). Most importantly, I learned things the last time and there were a few modules that I really wanted a do over on. I'm getting that chance and things are much more stable.
And so thankfully, despite a rewrite, Fitness Tracker will still be released on the Microsoft Store in the third quarter of 2025.
Have a beautiful day and thanks for following along
GH