Skip to content

Commit 2e67302

Browse files
committed
Initial commit
1 parent 9f5065f commit 2e67302

File tree

4 files changed

+6
-7
lines changed

4 files changed

+6
-7
lines changed

Sources/SwiftUIProtocols/Coordinator.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ public protocol Coordinator: EventHandler, Navigator {
1212
associatedtype StartContent: View
1313

1414
/// Provides the initial view for the coordinator when accessed directly by user interation.
15-
@ViewBuilder public func start() -> StartContent
15+
@ViewBuilder func start() -> StartContent
1616
}
1717

1818
public extension Coordinator {
19-
@ViewBuilder public func start() -> some View {
19+
@ViewBuilder func start() -> some View {
2020
Text("Providing views must be handled in the conforming class, not by the default implementation")
2121
}
2222
}

Sources/SwiftUIProtocols/EventHandler.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ public protocol EventHandler {
1313

1414
/// The means of sending a signal that a user event has occured and needs to be handled by the conforming object
1515
/// - Parameter event: An `Event` as defined in the conforming object
16-
public func send(_ event: Event)
16+
func send(_ event: Event)
1717
}
1818

1919
public extension EventHandler {
20-
public func send(_ event: DefaultEvent) {
20+
func send(_ event: DefaultEvent) {
2121
fatalError("Receiving events must be handled in the conforming class, not by the default implementation")
2222
}
2323
}

Sources/SwiftUIProtocols/Navigator.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ public protocol Navigator {
1313

1414
/// The means of providing the next view by the conforming object
1515
/// - Parameter destination: A `Destination` as defined in the conforming object
16-
@ViewBuilder public func view(for destination: Destination) -> ViewContent
16+
@ViewBuilder func view(for destination: Destination) -> ViewContent
1717
}
1818

1919
public extension Navigator {
20-
@ViewBuilder public func view(for destination: DefaultDestination) -> some View {
20+
@ViewBuilder func view(for destination: DefaultDestination) -> some View {
2121
Text("Providing views must be handled in the conforming class, not by the default implementation")
2222
}
2323
}

Tests/SwiftUIProtocolsTests/SwiftUIProtocolsTests.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,5 @@ final class SwiftUIProtocolsTests: XCTestCase {
66
// This is an example of a functional test case.
77
// Use XCTAssert and related functions to verify your tests produce the correct
88
// results.
9-
XCTAssertEqual(SwiftUIProtocols().text, "Hello, World!")
109
}
1110
}

0 commit comments

Comments
 (0)