title: How do I select a specific id from a JSON file in swift?
body: <p>I'm trying to just select one of the entries in my JSON file and am struggling to do so. Here is the list part of my code so far:</p>
  <pre><code>    var body: some View {
          
          NavigationView {
              Group {
                  List {
                      ForEach(regions) { regions in
                     NavigationLink(destination: RegionsListView(regions: regions)) {
                         RegionButtonView(regions: regions)
                     }
                }
          }
              }
          }
          }
  </code></pre>
  <p>And here is the <code>if statement</code>:</p>
  <pre><code>    let regions: Region
      
      var body: some View {
          if regions.id != nil {
              SCaliView()
          } else if regions.id != nil {
              BAView()
          }
      }
  }
  </code></pre>
  <pre><code>struct Region: Codable, Identifiable {
      let id: Int
      let name: String
      let image: String
  
  }
  </code></pre>
  <p>I want to make it so that when a certain <code>id</code> is selected, it will go to a certain view.</p>