› Elliot Jackson

Hi, I’m Elliot Jackson. I’m a product designer turned software developer keen on building, problem solving, performance and databases. As can be seen by the articles here, my interest in recent years has been in the Swift and Rust ecosystems. I still mostly write Swift professionally (and would love the opportunity to write Rust professionally), but I also believe the wonderful Elixir has a very bright future and am focussing a lot on that at the moment too.

I currently freelance but am interested in joining a team full-time writing Rust and/or Elixir. If your team is hiring, please hit the email button below!


The problem GIFs are great but sometimes it could be nice to have a little bit of dynamism on a site without having a GIF changing in a loop and distracting the user or just without adding the file size of a GIF to the page load. The solution What we’re going to build is a small Phoenix web app that has a single endpoint, /quote.png, that will return an image of a random quote and attribution from an array of user defined quotes.
Written for Phoenix 1.5.7 & Ecto 3.5.5 Ecto changesets provide common validation options but we can also write our own. Before we get into writing our own though, we need to understand how (most of) the default validators work. Let’s have a look at the definition of validate_inclusion for example: def validate_inclusion(changeset, field, data, opts \\ []) do validate_change changeset, field, {:inclusion, data}, fn _, value -> if value in data, do: [], else: [{field, {message(opts, "is invalid"), [validation: :inclusion, enum: data]}}] end end We can see that the actual logic is wrapped inside validate_change/4.
In part 1: “Getting started with GRDB”, we covered how to setup a local SQLite database for your iOS app, how to write migrations, how to adopt GRDB’s protocols within a struct that can then be saved to the database, and lastly we went over some basic querying. In part 2, we’ll have a look at how to observe and react to changes in the database, how to define relationships between tables, and how to save a custom types.
Designed to provide local data storage for individual applications and devices, SQLite is a small, fast, highly reliable SQL database engine that I have a lot of love for. GRDB is a fantastic SQLite toolkit maintained by Gwendal Roué that does all the hard work for us: it provides, amongst other features, a query interface so we don’t have to write raw SQL (though you can still do that if you need to), migrations, database observation, and encryption.
I got an Amazon Echo Dot a couple of months ago — my first voice assistant and the only one I’ve used. I’ve found it to be largely underwhelming on the software front. Maybe I just set my expectations too high because of all the wonderful things the people I follow have been saying about it since its release. The following is neither a rant about nor a full review of the software.
Nearly 4 months ago to the day I setup a publishing workflow for this site that allows me to create, update, and delete content via Google Drive. It’s a setup that has worked flawlessly for me. In my quest to streamline the blogging process as much as possible, I also wrote a couple of scripts around the same time. The first to create a new post, the second to publish the post currently open in Vim.
« Older posts Newer posts »