title: Change the tab selection color in TabBar SwiftUI
body: <p>I am trying to change the color of selected tab in TabBar, but nothing worked. I can change the TabBar <code>backgroundColor</code> by writing         </p>
  
  <pre><code>struct ContentView: View {
      init() {
          UITabBar.appearance().backgroundColor = UIColor.purple
      }
      var body: some View { 
      }
  }
  </code></pre>
  
  <p>In swift, we set <code>tintColor</code> and it does change the color of selected tab. But what do i need to do for swiftUI?</p>
  
  <p>Here is my code,</p>
  
  <pre><code>    TabView(selection: $selection) {
          AView()
              .tabItem {
                  VStack {
                      Image(systemName: "bubble.left.and.bubble.right")
                      Text("A Tab")
                  }
          }.tag(0)
  
          BView()
              .tabItem {
                  VStack {
                      Image(systemName: "house")
                      Text("B Tab")
                  }
          }.tag(1)
  
          CView()
              .tabItem {
                  VStack {
                      Image(systemName: "circle.grid.3x3")
                      Text("C Tab")
                  }
          }.tag(2)
      }
  </code></pre>
  
  <p>Any help with this?
  Thanks in advance!!</p>