This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// UserDefaults KVO observation with AsyncSequence/AsyncStream | |
// Ole Begemann, 2023-04 | |
// Updated for Swift 6, 2024-11 | |
// https://gist.github.com/ole/fc5c1f4c763d28d9ba70940512e81916 | |
import Foundation | |
// This is ugly, but UserDefaults is documented to be thread-safe, so this | |
// should be OK. | |
extension UserDefaults: @retroactive @unchecked Sendable {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
import UIKit | |
/// Used to create a layout guide that pins to the top of the keyboard | |
final class KeyboardLayoutGuide { | |
private let notificationCenter: NotificationCenter | |
private let bottomConstraint: NSLayoutConstraint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
UI- and App Frameworks Evangelist - Jake Behrens, [email protected], twitter: @Behrens | |
- What's new in Cocoa | |
- Accessibility in iOS | |
- Building User Interfaces for iOS 7 | |
- Getting Started with UIKit Dynamics | |
- What's new in Cocoa Touch | |
- What's New With Multitasking | |
- Best Practices for Cocoa Animation | |
- Improving Power Efficiency with App Nap | |
- Introducing Text Kit |