Skip to content

Instantly share code, notes, and snippets.

@alinebee
alinebee / RegExp.swift
Created November 29, 2017 18:27
A Swift 2-era extension library to make NSRegularExpression less obnoxious
//
// RegExp.swift
//
// Created by Alun Bestor on 18/11/14.
// Copyright (c) 2014 Alun Bestor. All rights reserved.
//
import Foundation
/// Alias to make `NSRegularExpression` less odious to type.
@alinebee
alinebee / UICollectionViewPlayground.swift
Last active April 10, 2017 18:09
UICollectionView performBatchUpdates crash demo
//: Playground - noun: a place where people can play
import UIKit
class MockDataSource: NSObject, UICollectionViewDataSource {
let collectionView: UICollectionView
var numItems: Int
init(numItems: Int, collectionViewFrameSize: CGSize) {