I’m using @Environment(.requestReview)
in my app to request reviews. However, when requestReview()
is called, the screen freezes before the review prompt appears. Animations continue to play as expected, but I lose the ability to interact with the UI (e.g., tapping buttons, scrolling lists, etc.) during this period. Here’s the relevant code:
@Environment(.requestReview) private var requestReview
var body: some View {
NavigationView {
// View content
}
.onChange(of: rstatus) { newValue in
switch newValue {
case .ready:
Task { @MainActor in
requestReview()
}
// Other cases omitted for brevity
}
}
}
How can I prevent this screen freeze and ensure a smoother transition when requesting a review?
5