Nice and simple replacement of a boring spinner loader. Do not block your users while the data is on the way!
- Import the package
import ShimmeringView
- Add the function to your view as per example
HStack {
Image("ic_def_avatar")
.padding()
Text("Hello")
.padding()
}
.shimmering()
- Swift 5.5+
- iOS 14.0+, macOS 11.0+
SwiftUI-ShimmeringView
is available through Swift Package Manager.
To add package go to File -> Swift Packages -> Add Package Dependancy
name: "SwiftUI-ShimmeringView"
url: https://github.com/Ninise/swiftui-shimmeringview.git
version: 1.0.0