Swift
Building the log in interface
To be able to log in, you will need to add three elements to the screen:
- A
Buttonto log in Alice - A
Buttonto log in Bob
Open ContentView.swift and add it programmatically:
import SwiftUI
struct ContentView: View {
var body: some View {
NavigationStack {
VStack {
Button("Login as Alice") {
Task {
}
}.buttonStyle(.bordered)
Button("Login as Bob") {
Task {
}
}.buttonStyle(.bordered)
}
.padding()
}
}
}
Build and Run
Run the project again (Cmd + R) to launch it in the simulator.

Creating an iOS chat app
Create a iOS application that enables users to message each other
手順
1
Introduction to this task2
Prerequisites3
Create a Vonage Application4
Create a conversation5
Create the users6
Generate JWTs7
Xcode Project and Workspace8
Building the log in interface9
VGChatClient10
Building the chat interface11
Chat events12
Sending a message13
What's next?