Skip to content

Instantly share code, notes, and snippets.

@schahriar
Created January 14, 2018 11:02
Show Gist options
  • Save schahriar/9645c2ae29903a3459e9f8f13f1d4bf1 to your computer and use it in GitHub Desktop.
Save schahriar/9645c2ae29903a3459e9f8f13f1d4bf1 to your computer and use it in GitHub Desktop.
Control flow parallel #async-await #medium
const [user1, user2] = await Promise.all([db.get('user1'), db.get('user2')]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment