Custom View Dialog in SwiftUI
Reading time: 1 min
This recipe show how to display a custom dialog in SwiftUI. You can customize the dialog content in any way you want.
Pager / Swiper View in SwiftUI
Reading time: 3 min
This recipe shows how to implement a swipeable pager view in SwiftUI.
Timers and countdowns in SwiftUI
Reading time: 1 min
This recipe shows how to implement a timer in SwiftUI in order to update the UI state at a specific interval.
There are two ways of going about it:
- The simple one, with
onReceive
. - A bit more complex, but also more powerful one, using
SimpleTimer
wrapper.
Reading time: 3 min
Here's a quick tip for resolving a common and annoying error that you'll occasionally see. The error message is
Function declares an opaque return type, but the return statements in its body do not have matching underlying types
and you can see it if you declare a function or a property that returns some View
and the body has multiple returns.
Star rating view in SwiftUI
Reading time: 1 min
This recipe shows how to implement a star rating view in SwiftUI.