Aaron Presley

Cocoapods Not Finding Modules

I let an XCode project sit unchanged for a while, and when I got back to it I was getting the following error…

Multiple Node Versions With Full ICU

I have a few different projects that all rely on a different version of node. In a perfect world, I’d be able to use the Node Version Manager. However, currently the nvm command breaks when passing the –with-intl=full-icu argument (see GitHub Issue here). What I have to do instead, is build multiple versions of node from source, and manually switch. […]

Mocking the Javascript Intl Object with Jest

I wrote a method to check whether or not the given environment (the browser or the node environment) has native Intl support. There’s a bit of a trick to this because there’s three possible states: Intl is not supported Intl is supported, but was only installed with system-icu (the default for node) Intl is supported, and was installed with full-icu support Here’s the method, […]

Determine if on iPhone X in React Native

With the release of the iPhone X, I’ve found myself needing to have special conditions in a few of my React Native styles. Below is what I’m using to do that check. That’s it! Easy as that.

Simple React Project Boilerplate

A lot of the current React Boilerplate projects feel so bloated to me, with a ton of extras that I don’t need. I’ve created this simple React Boilerplate that has the absolutely bare minimum that I need: webpack, stylus, and karma. No other bells or whistles. Enjoy! View Code

My Sourdough Recipe

Over the past few months, I’ve been teaching myself how to make sourdough bread. With a lot of different input from a lot of different people, I’ve figured out my preferred recipe. I’ll keep this post updated as I tweak my methods. Refrigerator Starter The first thing you need is your own starter to pull […]

Disable Screen Sleep on Raspberry Pi

There are many different links recommending you update many different config files to disable the screen from sleeping on a Raspberry Pi, but this is the simplest solution I’ve come across: Now open the app Click Settings, then at the top choose Disable Screen Sleep from the dropdown. Now you’re done!

Including External Template Files in a Backbone App Without a Server

I have a simple Backbone app that is being compiled down using gulp and browserify. I wanted to be able to include my template file with a simple node require() method, but node doesn’t like importing anything but JS files. If I tried pulling in the template HTML with jQuery’s $.get() method, as is often recommended, I was getting a CORS error […]

Resize UIImage Largest Side in Swift

I’m knee deep in Swift these days, and am working a lot with the UIImage object. I couldn’t find a quick extension method that allowed me to resize an image based on the largest side, so I wrote one: You can use it like so: Good luck!

Search Query in URL Breaking WordPress Template

While creating a custom WordPress template, my site would crash when adding the search query string in the url. The url website.com/ worked fine, but once it became wordpress.com/?s=search+string it crashed without any kind of obvious errors. The problem was happening because I never specified the Post Page from within the Settings > Reading section of the Admin site. Once I did this […]

High Resolution Android Device Template

I’ve had a hell of a time finding a high resolution Android device on a blank background. Most of them have annoying glares or a dumb shadow that’s hard to cut around. Fear not, dear Googler – you can use mine. I also have an iOS one that I’ll upload when I get around to […]

Registering Nib Text Field Event in Parent View

I’ve created a custom UiTableViewCell nib with a text field, and I’ve had a hell of a time figuring out how to register text changes in my parent view. I didn’t find anything through Googling, so I figured I’d contribute the solution I figured out, using Swift: CustomTableViewCell.swift I created this file pretty simply. I […]

What Brew Notice Costs

I’m always fascinated when companies post their expenses publicly. I thought it’d be interesting to do something similar for Brew Notice, despite our small size. Here’s what it takes to serve ~700 users and check the tap lists of ~150 bars every few minutes: Item Monthly Cost brewnotice.com Domain Name $0.83 Roughly $10 per year SSL Certificate […]

Secure, Infrequent Posts

For no reason in particular, I’ve added SSL to this site. Yay me! Turns out you can get free SSL certs from, among several places, a site called StartSSL. Now you can read my very infrequent updates securely. You’re welcome.

Add Confirm Password Field to UserSerializer in Django Rest Framework

I’m pretty new to the Django Rest Framework in general, but I had a hell of a time figuring out how to add a “confirm_password” field to my UserSerializer model. The currently suggested methods seem overcomplicated for what I was wanting to do – which is just confirm and validate the user’s password! Eventually I realized I […]