JSFiddle - React, Tailwind, and code Playground

JavaScript

const res = () => new Promise(r => setTimeout(() => r("hello"), 1000));

async function waitForHello() {
	const hello = await res();
  console.log(hello);
}

waitForHello();
console.log("This is declared after the async function");