This is a simple set of views written in SwiftUI. It has a lightning animation and a rain animation.
You can install the package using Swift Package Manager
dependencies: [
.package(url: "https://github.com/doorhinge-apps/LightningAnimation.git", branch: "main")
]
Import the package in files you want to use it in.
import LightningAnimation
The lightningInterval parameter accepts a Double value. It changes how many seconds between each lightning bolt.
LightningBolt(lightningInterval: 3.0)
You can display a rain animation using the rain view in the package.
Rain()