Minor fixes, split files into folders

This commit is contained in:
Arkadiusz Fal
2021-08-20 00:38:31 +02:00
parent c1d9e02475
commit ea634390a6
26 changed files with 101 additions and 46 deletions

View File

@@ -0,0 +1,22 @@
import Siesta
import SwiftUI
struct PopularView: View {
@ObservedObject private var store = Store<[Video]>()
var resource = InvidiousAPI.shared.popular
init() {
resource.addObserver(store)
}
var body: some View {
VideosView(videos: store.collection)
#if !os(tvOS)
.navigationTitle("Popular")
#endif
.onAppear {
resource.loadIfNeeded()
}
}
}