title: Getting following error while performing npx create-react-app
body: <p>I tried reinstalling yarn, npm,</p>
  <p>Tried <strong>npm cache clean</strong> and <strong>yarn cache clean</strong>.</p>
  <p>Still facing the same problem while <em>npx create-react-app my-app</em></p>
  <pre><code>Installing packages. This might take a couple of minutes.
  Installing react, react-dom, and react-scripts with cra-template...
  
  yarn add v1.22.4
  [1/4] Resolving packages...
  error An unexpected error occurred: &quot;https://registry.yarnpkg.com/react: self signed certificate in certificate chain&quot;.
  info If you think this is a bug, please open a bug report with the information provided in &quot;C:\\Users\\suryanarayan.rath\\DMS-cloud\\resilient-app\\yarn-error.log&quot;.
  info Visit https://yarnpkg.com/en/docs/cli/add for documentation about this command.
  
  Aborting installation.
    yarnpkg add --exact react react-dom react-scripts cra-template --cwd C:\Users\suryanarayan.rath\DMS-cloud\resilient-app has failed.
  
  Deleting generated file... package.json
  Deleting generated file... yarn.lock
  Done.
  </code></pre>
  <p>In yarn-error.log it shows following</p>
  <pre><code>Error: self signed certificate in certificate chain
        at TLSSocket.onConnectSecure (_tls_wrap.js:1502:34)
        at TLSSocket.emit (events.js:314:20)
        at TLSSocket._finishInit (_tls_wrap.js:937:8)
        at TLSWrap.ssl.onhandshakedone (_tls_wrap.js:711:12)
  
  </code></pre>
  <p>I saw many similar questions which were posted earlier but could not find the right solution.</p>