title: Can someone explain Why i need to use await in 2 different functions to fetch json?
body: <p>Example:</p>
  
  <pre><code>    async function getInitialVideos(){
           const ans= await fetch(`https://www.googleapis.com/youtube/v3/search?part=snippet&amp;videoEmbeddable=true&amp;type=video&amp;key=${APIKEY}&amp;q=${'The Beatles'}`).then(res=&gt;res.json())
  
      }
  
      async function onInit() {
          await getInitialVideos()
            DoSomething()
  }
  </code></pre>
  
  <p>in this function i say wait for the promise to resolve and fetch me that json,
  why would i need await in the second function? </p>
  
  <p>i mean if i drop it the second functions starts executing before i get the values from the first.
  lets say i want that fetch function to be a const that always gets that value,
  how would i implement it and make sure it waits without waiting again in a different function?</p>