title: How to create a copy of state data minus some properties in React?
body: <p>I have state data that I want to convert to JSON such as</p>
  
  <pre><code>state = {
      name: “John”
      age: 24
      height: “180cm”
      id: 2
  }
  </code></pre>
  
  <p>How would I go about creating a copy of this state minus the id property?</p>
  
  <p>So</p>
  
  <pre><code>copy = {
      name: “John”
      age: 24
      height: “180cm”
  }
  </code></pre>
  
  <p>I’ve tried using the filter function but it doesn’t seem to work on this.state?</p>
  
  <p>Any help would be great.</p>