This file contains hidden or 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 ComposableArchitecture | |
| import SwiftUI | |
| struct <#Name#>State: Equatable {} | |
| enum <#Name#>Action: Equatable {} | |
| struct <#Name#>Environment {} | |
| extension <#Name#>Environment { |
This file contains hidden or 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
| protocol FooDelegate: AnyObject { | |
| func didReceive(value: Int) | |
| func didOpen() | |
| func didClose() | |
| } | |
| class Foo { | |
| weak var delegate: FooDelegate? | |
| func open() { |
This file contains hidden or 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
| /// iOS 15+ | |
| func isPrewarm() -> Bool { | |
| if let prewawrmEnv = ProcessInfo.processInfo.environment["ActivePrewarm"], | |
| prewawrmEnv == "1" { | |
| return true | |
| } else { | |
| return false | |
| } | |
| } |
OlderNewer