哥们 写的挺好,就是你这个}括号 多打了几个 直接拷贝有错误: stackView.addArrangedSubview(createCommonInput(label: "User Name:",
placeHolder: "Email/Phone/ID",
onTextChanged: { text in
print("User Name: \(String(describing: text))")}))
}
stackView.addArrangedSubview(createCommonInput(label: "Password:",
placeHolder: "Password",
onTextChanged: { text in
print("Password: \(String(describing: text))")}))
}
UIStackView 的另类玩法(一)UIStackView[https://developer.apple.com/documentation/uikit/uistackview] 是 iOS 9.0 引入的一...