Dejan Atanasov
1 min readMay 11, 2018

--

Hi Michael,

I am glad that you liked the tutorial.

The line that you have commented about is in fact really important. That's called a capture list and guards us from strong reference cycles that can occur when using closures.

For more details about this you can refer the official Swift documentation.

You will find examples on how to use [unowned self] and [weak self].

Cheers!

--

--

Dejan Atanasov
Dejan Atanasov

Written by Dejan Atanasov

Senior iOS & Android Developer | Creator of Swift2Go | @hackernoon writer | Hire Me: http://bit.ly/2XfxbBR

Responses (1)