Migrating my website from Scala to Deno

I moved my website from Scala to TypeScript / Deno. While that leaves me with a crying heart, there's ... reasons.

A bit of history

I started a personal website quite a while ago, but the current design stems from a rework in 2016. While NodeJS — and actually even React (May 2013) — had been around for quite a while at the time, web frameworks like NextJS were just starting to pop up or gain traction. The lack of respective tooling, communities, etc., combined with my ❤️ for (and experience with) Scala, led me to build the website in Scala / ScalaJS.

Interestingly enough, already at that time it was reasonably straightforward to build a website with a shared codebase, server-side rendering, client islands, reactivity — all the fancy (re)inventions of modern web development — with Scala.

A shared codebase contained all the communication primitives, route definitions, as well as most of the templates to be rendered either by the server (on initial load) or by the client (for interactivity, but also to speed up subsequent page loads). The templates were not built with JSX, but using the excellent ScalaTags library, which allowed for type-safe HTML generation, and (with a bit of Scala.Rx) completely reactive page builds (think React useState and useEffect — or maybe, more like signals of alternative frameworks).

A smaller client codebase (that had the shared codebase injected) provided some client-only "islands", and a server controller (using the Play Framework) handled the initial page load and "admin things" such as authentication, website editing, mailing, etc.

A rework and why I moved to Deno

Fast forward to 2024: While the old website still worked reasonably well (and I still love Scala) I realized I was less and less motivated to keep it up to date, as the whole application was relatively complex (for a "simple" personal website), and as the Scala ecosystem had essentially moved on to Scala 3. It is likely also a bit due to the fact that at my current company c.technology we are not using any JVM language or technology, making keeping up to date with all Scala developments challenging. I did a rewrite in Scala 3 (these days you can just buy completely into the com-lihaoyi ecosystem, follow this setup, and get started very quickly), but ultimately wanted to move faster and have a more commonly used setup.

Enter Deno: I have used Deno since its inception, and while it has its drawbacks (mostly the compatibility with the NodeJS ecosystem), it is a very nice platform to work with, and I absolutely love TypeScript and the TS-first mentality. The excellent Fresh framework — though similarly not as feature-rich as its NodeJS counterparts — is a great starting point for a personal website, for which reasons I decided to go with it. Sometimes, less is more; I think this holds particularly true for something like a personal website, where I did not want to get distracted by working around a framework, but by pushing my ideas into the boundaries given by the framework, and simply getting things done.

So here we are now, about 8 years after the initial rework, with a fresh new website, built with Deno, TypeScript, and Fresh. For those interested, you can still find the old page here.