title: Alter query string param based off of checkboxes in react native
body: <p>I'm able to successfully run this code when a box is checked to filter results:</p>
  
  <pre><code>changeCheck = (index, acronym) =&gt; {
          if(!this.state.checkedLeagues.includes(acronym)){
              this.state.checkedLeagues.push(acronym)
          } else {
              this.setState({checkedLeagues: this.state.checkedLeagues.filter(v =&gt; { return v !== acronym})})
          }
          this.state.checked[index] = !this.state.checked[index]
          this.setState({ checked: this.state.checked })
  
  
  
  
          queryString = []
  
          console.log('newLeagues', newLeagues)
  
          this.state.checkedLeagues.map(
              (v, i) =&gt; {
                  if(queryString.length &lt; 1) {
                      queryString.push(`?league=${v}`)
                  } else if (queryString.length &gt;= 1 ) {
                      queryString.push(`&amp;league=${v}`)
                  }
              }
          )
  
          // console.log(queryString.join(''))
  
          axios.get(`http://localhost:4000/reports${queryString.join('')}`)
                  .then(response =&gt; {
                      this.props.loadCards(response.data)
                  })
      }
  </code></pre>
  
  <p>The issue comes when a box is unchecked.</p>
  
  <p>I need a way to remove the box that was unchecked from queryString if it already exists in this.state.checked.</p>
  
  <p>The value that is checked or unchecked is passed in on onPress/onClick through acronym.</p>
  
  <p>Edit:</p>
  
  <p>As an example:
  If this.state.checkedLeagues is an array of leagues ['NBA', 'NFL'], I only want to set those as query string paramaters in the axios get request.</p>
  
  <p>If I set the checkedLeagues to ['NBA', 'NFL'], it works. But when I uncheck it does not; lets say I uncheck 'NBA' (when I say uncheck, I mean remove from the queryString), it does not, because I do not have a mechanism remove the unchecked box from queryString.</p>