// // ActivityIndicator.swift // tst // // Created by Vitaly Takmazov on 10.12.2019. // Copyright © 2019 com.juick. All rights reserved. // import Foundation import SwiftUI struct ActivityIndicator: UIViewRepresentable { let style: UIActivityIndicatorView.Style func makeUIView(context: UIViewRepresentableContext) -> UIActivityIndicatorView { return UIActivityIndicatorView(style: style) } func updateUIView(_ uiView: UIActivityIndicatorView, context: UIViewRepresentableContext) { uiView.startAnimating() } } struct ActivityIndicator_Previews: PreviewProvider { static var previews: some View { /*@START_MENU_TOKEN@*/Text("Hello, World!")/*@END_MENU_TOKEN@*/ } }