ExtraLottie is a SwiftUI wrapper of Lottie-iOS

Overview

📝 What is ExtraLottie?

ExtraLottie is a SwiftUI wrapper of Lottie-iOS.

ℹ️ Info

Currently ExtraLottie supports custom loop mode, LottieLoopMode, starting animation from defined progress, looping animation with custom delay time.

🌐 Installation

Add package via SPM.

  1. Using Xcode 11 go to File > Swift Packages > Add Package Dependency
  2. Paste the project URL: https://github.com/kingkej/ExtraLottie.git
  3. Click on next and select the project target

⚙️ How to use

There are 3 available modes to start.

  1. Simply providing animation name as parameter. In that case loop mode is set to .loop.
ExtraLottieView(animationName: "filename")
  1. Providing animation name and LottieLoopMode (example: .loop or .playOnce)
ExtraLottieView(animationName: "filename", loopMode: .playOnce)
  1. Providing animation name, manualLoop - set true to use custom delay, delayBetweenLoop - specifies time between loops (in seconds), fromProgress - specifies progress to start animation, set 0 to start from the beggining.
ExtraLottieView(animationName: "filename", manualLoop: true, delayBetweenLoop: 5.0, fromProgress: 0)

Examples

This example makes animation view with loops. Delay between loops is 5 seconds.

import SwiftUI
import ExtraLottie

struct ContentView: View {
    var body: some View {
        ExtraLottieView(animationName: "64112-loading-bar-progress-bar", manualLoop: true, delayBetweenLoop: 5.0, fromProgress: 0)
    }
}

struct ContentView_Previews: PreviewProvider {
    static var previews: some View {
        ContentView()
    }
}
You might also like...
Yummies is my first attempt at building a native iOS app using Swift and SwiftUI

Yummies is my first attempt at building a native iOS app using Swift and SwiftUI. A recipe browser where you can pin your favorite ones. Powered by Edamam Recipe Search API.

Crypto & Portfolio Track SwiftUI - macOS 13 Ventura & iOS 16 & watchOS 9 - MVVM
Crypto & Portfolio Track SwiftUI - macOS 13 Ventura & iOS 16 & watchOS 9 - MVVM

CryptoTrackMultiPlatformSwiftUI In this SwiftUI project, I developed a multiplatform app using as many new features as possible in the latest OS versi

I am learning to build an iOS app with SwiftUI.
I am learning to build an iOS app with SwiftUI.

ios-quiz-app I am learning to build an iOS app with SwiftUI. This is a quiz app with SwiftUI although tutorial was on UIKit Challenges Faced navigatio

an onboarding app built in SwiftUI
an onboarding app built in SwiftUI

hello hello is application onboarding macOS devices. Inspired by Kandji's Liftoff Logo created with Type with Pride font family Warning DO NOT USE THI

BioViewer - Protein (.pdb, .cif and .fasta) viewer for iPhone, iPad and Mac, using SwiftUI + SceneKit
BioViewer - Protein (.pdb, .cif and .fasta) viewer for iPhone, iPad and Mac, using SwiftUI + SceneKit

BioViewer - Protein (.pdb, .cif and .fasta) viewer for iPhone, iPad and Mac, using SwiftUI + SceneKit

Create an easy to peek SwiftUI View to showcase your own data, catalog, images, or anything you'd like.
Create an easy to peek SwiftUI View to showcase your own data, catalog, images, or anything you'd like.

Create an easy to peek SwiftUI View to showcase your own data, catalog, images, or anything you'd like.

An Apple Watch remake of the Poketch from Pokemon Diamond and Pearl made with SwiftUI
An Apple Watch remake of the Poketch from Pokemon Diamond and Pearl made with SwiftUI

Apple Watch Poketch What is it? It's an Apple Watch remake of the "Poketch" from Pokemon Diamond and Pearl made with SwiftUI! Check out the YouTube vi

This is a fully functioning Guess The Flag game I created as part of my 100 days of SwiftUI course with Paul Hudson.
This is a fully functioning Guess The Flag game I created as part of my 100 days of SwiftUI course with Paul Hudson.

GuessTheFlag This is a fully functioning Guess The Flag game that was a part of my 100 days of SwiftUI course with Paul Hudson. In this app my challen

GraphQL based Jetpack Compose, Wear Compose and SwiftUI Kotlin Multiplatform sample
GraphQL based Jetpack Compose, Wear Compose and SwiftUI Kotlin Multiplatform sample

GraphQL based Jetpack Compose, Wear Compose and SwiftUI Kotlin Multiplatform sample

Releases(1.0.0)
Owner
null
Powerful property wrapper to back codable properties.

BackedCodable Powerful property wrapper to back codable properties. Why Swift's Codable is a great language feature but easily becomes verbose and req

Jérôme Alves 472 Dec 18, 2022
A property wrapper to enforce that closures are called exactly once!

A property wrapper that allows you to enforce that a closure is called exactly once. This is especially useful after the introduction of SE-0293 which makes it legal to place property wrappers on function and closure parameters.

Suyash Srijan 11 Nov 13, 2022
A Swift wrapper around the JSONbin.io API

A Swift wrapper around the JSONbin.io API

Fleuronic 5 Dec 16, 2021
SwiftyXPC - a wrapper for Apple’s XPC interprocess communication library that gives it an easy-to-use, idiomatic Swift interface.

SwiftyXPC is a wrapper for Apple’s XPC interprocess communication library that gives it an easy-to-use, idiomatic Swift interface.

null 36 Jan 1, 2023
Home Assistant Native iOS Application built with SwiftUI for iOS 15+

Home Assistant - Native iOS SwiftUI Application Screenshots Disclaimer - Please read This application is mostly a not-working mockup written in SwiftU

Alessio Santoru 34 Dec 13, 2022
Learning iOS Frontend: Aplikasi iOS Pemesanan Makanan dengan SwiftUI, WidgetKit, Google Fonts, dan Assets dari Figma

Foody Aplikasi Foody adalah Aplikasi iOS Pemesanan Makanan dengan SwiftUI, WidgetKit, Google Fonts, dan Assets dari Figma untuk Mempelajari Ilmu Front

DK 10 Aug 20, 2022
How to develop an iOS 14 application with SwiftUI 2.0 framework. How to create an Onboarding Screen with Page Tab View

Ama-Fruits USER INTERFACE AND USER EXPERIENCE APP DESIGN How to develop an iOS 14 application with SwiftUI 2.0 framework. How to create an Onboarding

Noye Samuel 1 Dec 11, 2021
Wiggles-iOS - Beautiful Puppy adoption app built to Demonstrate the SwiftUI and MVVM Architecture

Wiggles ?? Beautiful Puppy adoption app built to Demonstrate the use of SwiftUI

Sameer Nawaz 186 Dec 18, 2022
A project to practice the Platzi course, Curso de Desarrollo de Aplicaciones iOS con SwiftUI

A project to practice the Platzi course, Curso de Desarrollo de Aplicaciones iOS con SwiftUI

Joaquin Segovia 1 Mar 14, 2022
A collection of native SwiftUI layouts (iOS 16+)

SwiftUILayouts A library of commonly requested layouts. Implemented using SwiftUI's native layout system. NOTE: SwiftUILayouts requires iOS 16 or abov

Apptek Studios 25 Dec 26, 2022