Skip to content

Instantly share code, notes, and snippets.

@GerardPaligot
Last active March 16, 2022 21:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save GerardPaligot/71f7c6f8335ce551fb008de6e1c4775c to your computer and use it in GitHub Desktop.
Save GerardPaligot/71f7c6f8335ce551fb008de6e1c4775c to your computer and use it in GitHub Desktop.
var body: some View {
VStack {
// Generate form UI
Form {
// Generate section UI
Section {
TextField("Your email address*", text: $email)
.keyboardType(.emailAddress)
TextField("Your first name*", text: $firstName)
TextField("Your last name*", text: $lastName)
TextField("Your company", text: $company)
}
if let uiImage = qrCode {
Section {
Image(uiImage: uiImage)
.resizable()
.frame(width: 250, height: 250, alignment: .center)
}
}
Section {
Button("Create QRCode") {
onValidation(email, firstName, lastName, company)
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment