Keyboard Avoidance for SwiftUI Views
This is a cross-post from my blog on Advanced Swift Development. 👉 Click here to directly open this article.
Implement a SwiftUI ViewModifier that manages a keyboard when it covers a text field:
- 📱 Make a view keyboard-aware.
- 🚀 Take care of over-scrolling.
- 👨‍💻 Complete source code included.
The reason why I am not posting the full article here is that I don’t want Medium to sell my articles. I am giving all my content for free and that’s how it’s going to stay. As a reader you’ll also get better experience with code highlight and formulae.