SwiftUI 中的 TinderApp iOS 应用程序

SwiftUITinderApp

SwiftUI 中的 TinderApp-iOS 应用程序

SwiftUITinderApp iOS application + SwiftUI

SwiftUI :SwiftUI 是一种在 Apple 平台上为应用程序构建用户界面的新方法。它允许开发人员使用 Swift 代码定义 UI。

挡泥板

The code would look like this:

// MARK: Dashboard Screen

//CircleImageView struct CircleImageView: View {

var body: some View {
        Image("person1")
            .clipShape(Circle())
            .overlay(
                Circle().stroke(Color.white, lineWidth: 4))
            .shadow(radius: 10)
    }

}

struct CircleImageView_Previews: PreviewProvider { static var previews: some View { CircleImageView() } }

//User model struct User: Hashable, CustomStringConvertible {

var id: Int
let firstName: String
let lastName: String
let age: Int
let mutualFriends: Int
let imageName: String
let occupation: String

var description: String {
    return "\(firstName), id: \(id)"
}

}

Thanks

[SwiftUI] (https://developer.apple.com/xcode/swiftui/)

License

SwiftUITinderApp is available under the MIT license. See the LICENSE file for more info.

GitHub

点击跳转