Skip to content

Instantly share code, notes, and snippets.


Helder Pinhal hpinhal

  • Porto, Portugal
View GitHub Profile
hpinhal / ContentView.swift
Created May 17, 2022 17:20
Lottie AnimationView for SwiftUI
View ContentView.swift
import Lottie
import SwiftUI
struct ContentView: View {
var body: some View {
ZStack {
GeometryReader { reader in
.frame(maxWidth: reader.size.width, maxHeight: reader.size.height)
hpinhal / AppDelegateSwizzler.swift
Created July 23, 2020 10:10
Performing some swizzling magic on your AppDelegate
View AppDelegateSwizzler.swift
import UIKit
private typealias ApplicationDidBecomeActive = @convention(c) (Any, Selector, UIApplication) -> Void
private typealias ApplicationWillResignActive = @convention(c) (Any, Selector, UIApplication) -> Void
private struct AssociatedObjectKeys {
static var originalClass = "MyFramework_OriginalClass"
static var originalImplementations = "MyFramework_OriginalImplementations"