Crikey, a new draft is available!
G'Day!
I'm writing this enroute to Australia, which we're visiting for a short trip to see family and friends. This is the first flight I've taken that has free wifi. I'm not sure how I feel about this. It's definitely useful (I was able to send out this newsletter after all) but I've always found wifi-free travel to be one of my most productive writing and coding environments.
Before leaving I uploaded a new draft of the book, the first since making it available for sale. The significant additions are a good chunk of the chapter on dependency injection and the majority of a new case study on building a reactive system. Both need some work but the core content is there. If you have already purchased the PDF, download this update for free, If you haven't purchased it yet, now is a good time to do so: the price will be going up when the book is complete. Get it here.
In writing the book I wanted to restrict myself to well established techniques. As such I wasn't intending to cover so-called direct-style or algebraic effects. However, I'm beginning to reconsider that decision. I'm seeing more and more uses for direct-style effects, particularly the capability-passing style that Scala uses. For example, UI frameworks like the current crop of Javascript frameworks, or so-called immediate mode GUIs that are popular in Rust and C++, are essentially direct-style effect systems. These frameworks all rely on some implicit context that allows direct-style reactivity, in the case of the JS frameworks, or UI layout as a side effect in the immediate mode GUIs. These frameworks are implemented in languages that lack the ability to directly express capability-passing in a convenient way, but conceptually this is what's going on.
There is also a natural progression from both dependency injection and tagless final to direct-style effects, and I was going to say a few words about direct-style effects in the dependency injection chapter. This chapter is already quite long, so I think I'll split out the (currently unwritten) part that discusses interpreters as an approach to dependency injection and cover direct-style effects in this new chapter.
With an additional chapter I'll probably cut back on the case studies. All the chapters include examples, sometimes quite substantial, so I don't think case studies are important in and of themselves; they have to illustrate something that isn't already covered elsewhere. For example, the reactive system case study is really about applying the strategies for both design and implementation, and building a robust mental model. I think there is room for one more case study, but probably no more than that.
That's the current plan. If I can dodge the venomous snakes, spiders, fish, monotremes, and octopuses, and avoid the ravenous crocs, sharks, and drop bears, I'll be back at it in a little over two weeks!
Catch ya,
Noel