Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
calda committed Jul 27, 2023
1 parent 66a97db commit ace3433
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Sources/Public/Animation/LottieView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ public struct LottieView<Placeholder: View>: UIViewConfiguringSwiftUIView {

/// Creates a `LottieView` that asynchronously loads and displays the given `LottieAnimation`.
/// The `loadAnimation` closure is called exactly once in `onAppear`.
/// If you wish to call `loadAnimation` at a different time, you can use the `loadAnimationTrigger` chain function.
/// If you wish to call `loadAnimation` again at a different time, you can use `.loadAnimationTrigger(...)`.
public init(_ loadAnimation: @escaping () async throws -> LottieAnimation?) where Placeholder == EmptyView {
self.init(loadAnimation, placeholder: EmptyView.init)
}

/// Creates a `LottieView` that asynchronously loads and displays the given `LottieAnimation`.
/// The `loadAnimation` closure is called exactly once in `onAppear`.
/// If you wish to call `loadAnimation` at a different time, you can use the `loadAnimationTrigger` chain function.
/// If you wish to call `loadAnimation` again at a different time, you can use `.loadAnimationTrigger(...)`.
/// While the animation is loading, the `placeholder` view is shown in place of the `LottieAnimationView`.
public init(
_ loadAnimation: @escaping () async throws -> LottieAnimation?,
Expand All @@ -47,7 +47,7 @@ public struct LottieView<Placeholder: View>: UIViewConfiguringSwiftUIView {

/// Creates a `LottieView` that asynchronously loads and displays the given `DotLottieFile`.
/// The `loadDotLottieFile` closure is called exactly once in `onAppear`.
/// If you wish to call `loadAnimation` at a different time, you can use the `loadAnimationTrigger` chain function.
/// If you wish to call `loadAnimation` again at a different time, you can use `.loadAnimationTrigger(...)`.
public init(_ loadDotLottieFile: @escaping () async throws -> DotLottieFile?) where Placeholder == EmptyView {
self.init(loadDotLottieFile, placeholder: EmptyView.init)
}
Expand All @@ -69,7 +69,7 @@ public struct LottieView<Placeholder: View>: UIViewConfiguringSwiftUIView {

/// Creates a `LottieView` that asynchronously loads and displays the given `LottieAnimationSource`.
/// The `loadAnimation` closure is called exactly once in `onAppear`.
/// If you wish to call `loadAnimation` at a different time, you can use the `loadAnimationTrigger` chain function.
/// If you wish to call `loadAnimation` again at a different time, you can use `.loadAnimationTrigger(...)`.
/// While the animation is loading, the `placeholder` view is shown in place of the `LottieAnimationView`.
public init(
loadAnimation: @escaping () async throws -> LottieAnimationSource?,
Expand Down

0 comments on commit ace3433

Please sign in to comment.