JiggleKit is a revolutionary SwiftUI package that enables your Views to jiggle, like the iPhone home screen "jiggle mode". It has been developed by Vis Fitness for implementing a jiggle-mode-like functionality in the Vis iOS app. We think you're gonna to love it.
Note
Be sure to check out the package documentation here
Using this groundbreaking package is easy, as demonstrated by the following example:
struct JigglingRectangle: View {
var body: some View {
RoundedRectangle(cornerRadius: 12, style: .continuous)
.fill(Color.red)
.frame(width: 64, height: 64)
// That's it.
.jiggling()
}
.padding()
}
}However, for an even jigglier rounded rectangle, one can even set the intensity of the jiggling.
struct VeryJigglingRectangle: View {
var body: some View {
RoundedRectangle(cornerRadius: 12, style: .continuous)
.fill(Color.red)
.frame(width: 64, height: 64)
// Now that's some strong jiggling!
.jiggling(intensity: .vivacious)
}
.padding()
}
}Copyright Vis Fitness Inc. Licensed under the MIT License
This was inspired by this gist
