Well well. It's finally here. A hand crafted website, maybe not the shiniest or the snappiest. But at least it's my creation and not just another copy of Wordpress or any other off-the-shelf option. Sure, I didn't build it completely from scratch (when does that even count? if you build your own hardware?), but it's built on top of existing stacks (more details below).
So what now? As you might notice around here, things aren't exactly finished. You can look at this as a house you've just moved into, your bed is in, the kitchen is operable, but you still have the plain light bulbs for lamps and have to repaint at least half the house. But hey, you can live there. Same with this, I have many more ideas in mind and things that need fixing, but for now it's operable. There's a photo section with some fresh photos and as of today there's even an articles section where I can share some ideas, projects, etc.
I intend to keep this article here for a while as I continue to work on things, as a sort of public to-do list. So below you'll see some things that I have to work on. For now, feel free to click around a bit and come back later when there's more content!
As promised, I'd share some details about the stack here. For your info, I started this repo on Github in August 2022. At the time I started off with a NestJS back-end and Angular front-end. Also, I think I've had attempts to create a new website before 2022, but I don't remember exactly anymore. Between 2022 and today I have added NX (monorepo manager) and removed it later and I've gotten rid of Angular and switched to NextJS for the front-end.
That is where we currently stand, there's still a separate back-end and front-end. I know that NextJS can act as both, but I already had some working code for the back-end so I decided to keep that. Also, I know it's confusing, but yes we have NextJS and NestJS, don't get them mixed up. Furthermore there's Prisma as an ORM, Tailwind for styling and a handful of handy packages.
Seriously, the c (centi, or 1/100) should be squared, otherwise it makes no sense. Let’s say something is 10 cm x 10 cm. That is:
Whereas 100 cm2 would be
which is clearly not the same. Hence we should write
and all our problems are solved, yay! This of course goes for all other SI prefixes.
It had been forever since I took to the streets by night (actually it was only around 6 PM) armed with just my camera to take some pictures. Granted, I was somewhat inspired by Pierre T. Lambert, but then I also used to do this often years ago (I would link to the old blog, but it has degenerated into a backup on a dusty disk somewhere). Anyway, long story short, it was fun walking around again taking pictures of whatever seemed interesting. I decided to devote a blog article to the pictures for two reasons, firstly because I think it’s fun to share that I did this again. Secondly because I think not all of the pictures are interesting enough to put in the portfolio, if you want to call it that, but they’re fun enough to share within this context. So here they are.
Find the project here: mexenonline.danielkappelle.com
Corona, bla bla bla, Covid-19, bla, quarantine.
I’ll refrain from phrases such as crazy/weird/challenging/uncertain times. Or did I?
Here’s the thing, in the earlier weeks of the lock down, online drinks became a thing. I’ve never been a huge fan, but it was something. One thing was really missing though, some game to play during those drinks! I’m talking drinking games, obviously.
One of the most popular, if not the most popular, drinking games in Delft is called ‘Mexen’. I’ll spare you the details, but it entails throwing dice and of course some reasonable (or not so reasonable) amounts of beer.
In order to cheer up my fellow students, a friend and I (with the help of yet another friend) cooked up a little online version of that game. It didn’t take much longer than a week and a half before it was up and running and gaining popularity. Give that another week or two and it was pretty much bug free.
The project was built using Node.js as a server and an Angular client, which was built and styled mostly by my pal Tijs. Every player fires up a Socket.IO connection to the server and this way the game is kept in sync.
I was really surprised by the difficulty of getting all the game dynamics right, especially since it really is a very simple game. This started by figuring out exactly how the game works. Normally you just play the game, but now we had to find out the exact rule set. Once we thought we figured this out, we moved to building a finite state machine or FSM to model the game states and how to transition from one to another.
Then came the bugs. And there were a lot. Not only was our initial FSM not very neatly implemented, there were also a bunch of scenarios that we hadn’t seen coming. What if the player that is up next leaves the game right before his move? What happens if all players wait for one player to drink his drinks and then that player leaves? There were dozens of problems like these, but at some point we had the majority figured out and improved the FSM. There were also some stability improvements and there it was, a drinking game for our students. It was a very educative project and we’re happy with the result.
To give it that final touch Tijs even implemented a chat box with the old MSN Messenger sound effects, that got some laughs.
The game may not be as relevant anymore, it was at least fun while everyone was locked indoors and we had fun building it!