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
struct User: Equatable { | |
var firstName: String | |
var lastName: String | |
} | |
@main | |
struct MyApp: App { | |
@State var value = User(firstName: "", lastName: "") | |
@State var showEdit = false |
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 SwiftUI | |
// had to move this out here due to RubberBandSwitch is now generic | |
enum Const { | |
static let shapeSize: CGSize = .init(width: 90.0, height: 190.0) | |
static let cornerRadius: CGFloat = 26.0 | |
} | |
struct RubberBandSwitch<Icon: View>: View { | |