Articles from Brian Hicks

Primary tabs

Banish Type Tedium with JSON to Elm

Banish Type Tedium with JSON to Elm
When you’re writing JSON decoders, it’s helpful to understand what’s going on.
When you’re up in the clouds with your JSON workflow doing all sorts of fancy and advanced stuff, it’s great!

But what about when you don’t need all the fancy stuff?
(Or you’re just getting started?)

The Care and Feeding of Folds in Elm

Welcome back!
We’re in the middle of a series about implementing functional data structures in Elm.
In part one we implemented the skeleton of our sets using a binary search tree.
Last week, part two, we added membership tests and size to our set.
This week we’re going to make a quick pit stop to talk about how folds work, and next week we’ll implement them for our set.

Functional Sets, Part 1: Construction

Today we’re starting a series on building functional data structures using Elm.
The goal: build a native set implementation from first principles.
We’re going to reimplement the standard library’s Set API.
This is going to be a toy implementation, so we won’t optimize as much as we could, but we’ll be able to learn some new things!