// MARK: ScreenProviding
// Provide ScreenDataUI with SomeScreen
public protocol ScreenProviding {
func screen(forID id: String) -> AnyPublisher<SomeScreen, Error>
}
public struct MockScreenProvider: ScreenProviding {
// ...
}
public struct URLScreenProvider: ScreenProviding {
// ...
}
public struct FileScreenProvider: ScreenProviding {
// ...
}
// MARK: ScreenStoring
// Store SomeScreens for later
public protocol ScreenStoring {
func store(screens: [SomeScreen]) -> AnyPublisher<Void, Error>
}
public struct FileScreenStore: ScreenStoring {
// ...
}
// MARK: ScreenLoading
public protocol ScreenLoading {
func load(withProvider provider: ScreenProviding) -> AnyPublisher<[SomeScreen], Error>
}
// MARK: ScreenLoading Basic Implementation
extension SomeScreen: ScreenLoading {
// ...
}
ScreenDataNavigation
1.2.0
Handling ScreenData's Destinations
ServerDriven/ScreenDataNavigation-swift
What's New
Description
- Swift Tools 5.3.0
Dependencies
- ScreenData0.4.0
- FLet2.0.0