title: What is the difference between Promise.any() and Promise.race()
body: <p>What is the difference between <code>Promise.any()</code> and <code>Promise.race()</code>, and how do they get used differently?</p>
  <hr />
  <p>From <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise/any" rel="noreferrer">MDN</a>,</p>
  <blockquote>
  <p>Also, unlike Promise.race(), which returns the first settled value,
  this method returns the first resolved value. This method will ignore
  all rejected promises up until the first promise that resolves.</p>
  </blockquote>
  <p>So that brings me to, the difference between <strong>resolved</strong> and <strong>settled</strong>. Which then brought me to the MDN promises <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise" rel="noreferrer">page</a>, which <strong>then</strong> brought me to <a href="https://github.com/domenic/promises-unwrapping/blob/master/docs/states-and-fates.md" rel="noreferrer">States and Fates</a></p>
  <blockquote>
  <p>Being settled is not a state, just a linguistic convenience.</p>
  </blockquote>
  <p>So we have <code>Promise.any</code> and <code>Promise.race</code> for linguistic convenience? i.e. there <strong>is no</strong> difference. Another instance of this equality, is &quot;A promise whose fate is unresolved is necessarily pending.&quot; and &quot;We say that a promise is settled if it is not pending, i.e. if it is either fulfilled or rejected.&quot;.</p>
  <p>So if a promise is resolved, it is not unresolved, so it is not pending. So then, if it's not pending, it's settled. So resolved === settled.</p>