A Quick Coding Lesson On Go's ‘WaitGroup’ (vs. JavaScript's ‘PromiseAll’)

Written by wagslane | Published 2020/07/27
Tech Story Tags: golang | go | async | javascript | sync | waitgroup | programming | tutorial-for-beginners

TLDR A Quick Coding Lesson on Go's 'WaitGroup' (vs. JavaScript's 'PromiseAll) is a quick coding lesson on how to use Go's WaitGroup type. In Go, we want each network call to the server (the fetch() calls) to happen at the same time. In order to make sure that we wait for all of our functions to complete, but still allow them to execute at same time, we use a WaitGroup. Go uses the standard sync package's "WaitGroup" type to perform high-latency functions.via the TL;DR App

no story

Written by wagslane | Founder of Boot.dev. Whining about coding sins since 2011. Committing coding sins for the same.
Published by HackerNoon on 2020/07/27