title: VLCKit with SwiftUI
body: <p>I would like to use <strong>VLCKit</strong> with <strong>SwiftUI</strong>.</p>
  
  <p>why not AVPlayer ? because a some video formats are not supported.</p>
  
  <p>Here is my code:</p>
  
  <pre class="lang-swift prettyprint-override"><code>import SwiftUI
  import UIKit
  
  struct ContentView: View {
      var body: some View {
          NavigationView
              {
                  VStack{
                      PlayerView(url: "https://bitdash-a.akamaihd.net/content/sintel/hls/playlist.m3u8")
                  }
          }
      }
  }
  struct PlayerView: UIViewRepresentable {
      public var url: String
      let mediaPlayer = VLCMediaPlayer()
      func makeUIView(context: Context) -&gt; UIView {
  
          let controller = UIView()
          mediaPlayer.drawable = controller
          let uri = URL(string: self.url)
          let media = VLCMedia(url: uri!)
          mediaPlayer.media = media
          mediaPlayer.play()
          return controller
      }
  
      func updateUIView(_ uiView: UIView, context: UIViewRepresentableContext&lt;PlayerView&gt;) {
      }
  }
  </code></pre>
  
  <p>This works and load the video but I would like to add playback controls (Full Screen, Play/Pause, forward, etc.).</p>
  
  <p>I didn't find any documentation about this can anyone help me a bit,</p>
  
  <p>Thanks</p>