Skip to content

Commit

Permalink
Fix the issue when Token and User info Views ould sometimes hang the app
Browse files Browse the repository at this point in the history
  • Loading branch information
vahancouver committed Dec 2, 2024
1 parent f3994d2 commit 133288a
Showing 1 changed file with 13 additions and 14 deletions.
27 changes: 13 additions & 14 deletions SampleApps/PingExample/PingExample/AccessToken.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,27 +16,26 @@ struct AccessTokenView: View {

var body: some View {
VStack {

TextEditor(text: $accessToken.accessToken)
.foregroundStyle(.secondary)
.padding(.horizontal)
.navigationTitle("AccessToken")
ScrollView {
Text($accessToken.accessToken.wrappedValue)
.foregroundStyle(.secondary)
.padding(.horizontal)
.navigationTitle("AccessToken")
}
}

}
}

struct UserInfoView: View {

@StateObject var vm = UserInfoViewModel()
@StateObject var userInfoViewModel = UserInfoViewModel()

var body: some View {

TextEditor(text: $vm.userInfo)
.foregroundStyle(.secondary)
.padding(.horizontal)
.navigationTitle("User Info")


ScrollView {
Text($userInfoViewModel.userInfo.wrappedValue)
.foregroundStyle(.secondary)
.padding(.horizontal)
.navigationTitle("User Info")
}
}
}

0 comments on commit 133288a

Please sign in to comment.