Skip to content

Instantly share code, notes, and snippets.

View calda's full-sized avatar

Cal Stephens calda

View GitHub Profile
@calda
calda / Map Sorting.md
Created April 10, 2019 14:16
Map Sorting
@calda
calda / EvolutionProposalPlayground.swift
Created February 23, 2020 22:58
Swift Nested JSON Decoding example
import Foundation
struct EvolutionProposal: Codable {
var id: String
var title: String
var reviewStartDate: Date
var reviewEndDate: Date
enum CodingKeys: String, CodingKey {
@calda
calda / results.txt
Created August 8, 2021 16:22
Survey of [weak self] unwrapping on GitHub Swift code search
GitHub search for “weak self”: https://github.com/search?l=Swift&p=1&q=%22weak+self%22&type=Code
Page 1
Result 1 guard else return
Result 2 guard else return
Result 3 invalid search result
Result 4 if let
Result 5 if let
Result 6 self?.
Result 7 self?.
Result 8 guard else return