title: How to use useHistory() hook in Class Component Type Script
body: <p>Hello I am trying to use</p>
  <pre><code>this.history.push({
                      pathname: `/search-results`,
                      search: `${job}$${location}`
                    }) 
  </code></pre>
  <p>In my class component that is using type script .
  However it is giving me back an error of Property 'history' does not exist on type 'Banner'.  TS2339</p>
  <p>I can see other examples of functional component, you can do <code>const history = useHistory();</code> and use history.push from hook.</p>
  <p>How can I do the same thing in class component?</p>