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
@_functionBuilder struct SwitchExpression { | |
static func buildBlock<T>(_ content: T) -> T { | |
return content | |
} | |
static func buildEither<T>(first: T) -> T { | |
return first | |
} | |
static func buildEither<T>(second: T) -> T { |
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 | |
@propertyWrapper | |
struct SimpleUserDefault<T> { | |
let userDefaults: UserDefaults | |
let key: String | |
let defaultValue: T | |
init( | |
userDefaults: UserDefaults = UserDefaults.standard, |
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 { useEffect, useRef } from "react"; | |
type GestureType = | |
| "swipeUp" | |
| "swipeDown" | |
| "swipeLeft" | |
| "swipeRight" | |
| "tap" | |
| "pinch" | |
| "zoom"; |
OlderNewer