yattee/Apple TV/SearchView.swift

20 lines
424 B
Swift
Raw Normal View History

2021-06-11 12:36:26 +00:00
import SwiftUI
struct SearchView: View {
@State var query = ""
@ObservedObject private var provider = SearchedVideosProvider()
var body: some View {
VStack {
SearchedVideosView(provider: provider, query: $query)
.searchable(text: $query)
}
}
}
struct SearchView_Previews: PreviewProvider {
static var previews: some View {
SearchView()
}
}