Skip to content

Commit 0b96d7d

Browse files
committed
Nest Action type.
#667 (comment)
1 parent 237510f commit 0b96d7d

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Shared/Supporting Files/Extensions/View+OnTeardown.swift

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -44,14 +44,14 @@ extension View {
4444
}
4545
}
4646

47-
/// A type of action to perform.
48-
private enum Action {
49-
case action(() -> Void)
50-
case actionAsync(() async -> Void)
51-
}
52-
5347
/// A view modifier that runs a teardown action when the view disappears.
5448
private struct OnTeardown: ViewModifier {
49+
/// A type of action to perform.
50+
enum Action {
51+
case action(() -> Void)
52+
case actionAsync(() async -> Void)
53+
}
54+
5555
/// The teardown action to perform.
5656
let action: Action
5757

0 commit comments

Comments
 (0)