Enjoy the detours!

pelletyze

Pelletyze — Update #5

Finally, I was able to work again on my Pelletyze project. 🥳

The Bug

There was a bug, where the checkbox was not recognized and the formData I've sent to the server was empty. This feature worked in the past and I don't understand why it broke.

The Fix

Because I use the @radix-ui/react-checkbox and don't handle the state manually, I need to wrap with a @radix-ui/react-form. That's it. 😎

While I was working on the component, I also transformed it into a server component. Which was easily done, by using getTranslation() from next-intl instead of useTranslation and making the component asynchronous.

The bug was the reason I've implemented the delete-all Button. To save me a trip to the Supabase admin page and clear the table.

This was my Sunday contribution to Pelletyze.


10 of #100DaysToOffload
#pelletyze
Thoughts? Discuss...

This update is small. I've fixed a small bug on mobile view and updated the CHANGELOG.md, which I forgot after the last release. Now everything is as it should be.

Here, on the left is the bug and on the right the fixed version.

Sadly, I don't have time for more at the moment. But I think it is better than nothing.


07 of #100DaysToOffload
#TheMonthProject #pelletyze
Thoughts? Discuss...

Today, just a small update. Yesterday I forgot to commit my changes. While I was on, I prepared the new release, which I thought I already did it in December.

So, I just did some small clean up tasks. Updating the CHANGELOG.md, and tagging the current commit with the version number v0.5.0-alpine-shepherd-boy. Because I'm a massive fan of the series Better Call Saul, my version names will have the names of episodes from BCS.

And that's it for #TheMonthProject update #3. Furthermore, this is post 5 in the #100DaysToOffload challenge. The pressure to complete round 1 did something to me. I already have 5 posts within the first week. Which makes me happy. Seems like I'm now in some flow of writing blog posts. 🥳


05 of #100DaysToOffload
#TheMonthProject #pelletyze
Thoughts? Discuss...

Today, I've implemented a “delete all” button. To have the opportunity to just delete all entries. This is just a convenient feature so that I don't have to do it directly in Supabase. I don't know if a real user would need this, but it was easy to implement and saves me some steps. Most of the delete logic is already implemented, I just needed to generalize the button and the action. Doing Server Actions in Next.js is straightforward to implement.

The most time was used on the question, where I should put this button. While on it, I also fixed some minor style issues for desktop and mobile.

That's it for today's #TheMonthProject effort. Going +50 min on this simple topic feels a bit long. But anyway, progress is still progress. 👋


04 of #100DaysToOffload
#TheMonthProject #pelletyze
Thoughts? Discuss...

After spending some family time, the House is now relatively quiet because 50% of the Family members are sleeping. Which is a good time, to do some side-project work.

For some time, I'm working on a pellet analyze site. I collect the data, when and how many pellet bags I refill in our tank. Which will give me then an overview of how many pellets we used in the past. With this data, I can see at which time we turned on the heating in the house or have a before and after view after we did the house insulation. It's not much and I keep adding some smaller features. Currently, it will give me a number, on which I can roughly estimate how we need for the year. Because the storage is nearly empty, and I need to get more.

For the app, I've created a small script which will fetch the current price of 1t of pellets. It is running inside a cron job. And by occasionally checking the app, I can see when the price is good and should order new pellets.

Lately, I've found a bug, where the fetched price is not the same as I can see on the page of the supplier. So I've done some investigation and found out, that I missed a combination of query parameters. While I was on it, I removed some I didn't need anymore. I'm happy that the page of the supplier is stable without changing the API a lot.

That's it for today. This was my contribution to #TheMonthProject. I've done a minimal introduction of my pellet analyze side-project and fixed a long-overdue bug. 😃


02 of #100DaysToOffload
#TheMonthProject #pelletyze
Thoughts? Discuss...