This library might come in handy when you have a lot of compile-time platform checks in your code.
import SwiftUI
import PlatformSpecificValue
struct ContentView: View {
private let shapeRadius: Int = platformSpecific(.macOS(15), .iOS(20))
var body: some View {
RoundedRectangle(cornerRadius: shapeRadius)
}
}
link |
Stars: 1 |
Last commit: 1 year ago |
Added interface with variadic arguments.
Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics