Skip to content

Instantly share code, notes, and snippets.

@JaviLorbada
JaviLorbada / FRP iOS Learning resources.md
Last active February 21, 2024 01:16
The best FRP iOS resources.

Videos

@JaviLorbada
JaviLorbada / CustomFontPlayground.swift
Created August 31, 2015 19:09
Load custom fonts within Swift playgrounds
//: Playground - noun: a place where people can play
import UIKit
let fontURL = NSBundle.mainBundle().URLForResource("PillGothic300mg-bold", withExtension: "ttf")
CTFontManagerRegisterFontsForURL(fontURL!, CTFontManagerScope.Process, nil)
var pillGothicFontBold = UIFont(name: "PillGothic300mg-bold", size: 30)
var attrs = [NSFontAttributeName : pillGothicFontBold!,
@JaviLorbada
JaviLorbada / RAC ViewModel Action on button pressed
Last active April 13, 2017 14:41
RAC ViewModel Action after button pressed with textfield char count as button enabled condition
import Result
import ReactiveCocoa
import ReactiveSwift
import UIKit
import XCPlayground
struct ViewModel {
// do not expose the implementation detail
private let (codeSignal, codeSink) = Signal<String, NoError>.pipe()
@JaviLorbada
JaviLorbada / buddybuild_postclone.sh
Created May 7, 2017 16:19
buddybuild_postclone phase
echo "Updating Swiftlint..."
brew uninstall --force swiftlint
brew install swiftlint
brew switch swiftlint 0.18.1
echo "Creating Xcodeproj..."
swift package generate-xcodeproj \
--enable-code-coverage
echo "Xcodebuild tests!"