open-swiftui-animations  by amosgyamfi

SwiftUI animation examples for iOS, macOS, visionOS, and watchOS

Created 6 years ago
5,012 stars

Top 9.9% on SourcePulse

GitHubView on GitHub
1 Expert Loves This Project
Project Summary

This repository provides a collection of pure SwiftUI animation examples for iOS, macOS, visionOS, and watchOS development. It aims to inspire developers to create custom, expressive animations directly within SwiftUI, negating the need for external animation libraries for common effects like loading, fading, and transitions.

How It Works

The project leverages SwiftUI's built-in animation capabilities, including PhaseAnimator, Symbol Effects, KeyframeAnimator, and spring animations. Animations are often derived from Apple Developer Documentation examples, demonstrating techniques like dash phase for moving borders, trimming for animated signatures, and various spring-based reactions for expressive UI elements.

Quick Start & Requirements

  • Clone the repository: git clone https://github.com/amosgyamfi/open-swiftui-animations.git
  • Open the .xcodeproj file in Xcode.
  • Requires Xcode and a recent macOS version.
  • Some examples may require specific iOS/visionOS SDKs.
  • A "Spark.png" image is needed for the Fireworks Animation example.
  • Official Xcode project for examples: [Link to Xcode Project]

Highlighted Details

  • Demonstrates advanced SwiftUI animation features like PhaseAnimator and Symbol Effects.
  • Includes examples of spring animations for realistic motion.
  • Showcases techniques for creating custom loading, transition, and background animations.
  • Features specific examples for Vision Pro 3D rotation and string character manipulation.

Maintenance & Community

  • Maintained by Amos Gyamfi.
  • Contact via X: @amos_gyamfi for suggestions or contributions.
  • Future animations planned using Gemini 2.5 Pro, Claude 3.7 Sonnet, and OpenAI o3/o4-mini.

Licensing & Compatibility

  • The repository does not explicitly state a license in the provided README.

Limitations & Caveats

The README indicates that several advanced animations are "Add soon," suggesting the repository is a work in progress with incomplete content. Some examples may require specific OS versions or assets not included by default.

Health Check
Last Commit

3 weeks ago

Responsiveness

1+ week

Pull Requests (30d)
0
Issues (30d)
0
Star History
64 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.