title: How to hide componentWillMount warnings
body: <p>I'm getting four big warnings that can not be minimized in my console. These warnings are from what I understand not because I have done anything wrong, but because react-router-dom and react-select use the deprecated componentWillMount function. How do I get rid of the warnings?</p>
  
  <p>I have tried looking up the problem on this site, but the closest to a solution I have found is <a href="https://stackoverflow.com/a/49166225/12057512">https://stackoverflow.com/a/49166225/12057512</a>. Since the answer is from over a year ago I am wondering if this is still the case. Have these big/popular npm packages still not updated since then?</p>
  
  <p>This is one of the warnings I get (the others are similar):</p>
  
  <blockquote>
    <p>react-dom.development.js:11494 Warning: componentWillMount has been
    renamed, and is not recommended for use. See https:// fb .
    me/react-async-component-lifecycle-hooks for details.</p>
    
    <ul>
    <li>Move code with side effects to componentDidMount, and set initial state in the constructor.</li>
    <li>Rename componentWillMount to UNSAFE_componentWillMount to suppress this warning in non-strict mode. In React 17.x, only the UNSAFE_ name
    will work. To rename all deprecated lifecycles to their new names, you
    can run <code>npx react-codemod rename-unsafe-lifecycles</code> in your project
    source folder.</li>
    </ul>
    
    <p>Please update the following components: BrowserRouter, Route, Router,
    Switch</p>
  </blockquote>
  
  <p>(I actually tried to run "npx react-codemod rename-unsafe-lifecycles" but it made no difference)</p>
  
  <p>I have no control over how these npm packages work internally, so I find it frustrating that I constantly get these warnings that I can not fix or remove.</p>