willSet method swift programming – how it works ?

By | July 21, 2016

willSet method swift programming

The code that’s written in this method is run anytime outside the initializer.

On setting up square sideLength, it will set the triangle sideLength by self. There’s another method didSet as well and that we will see in later on posts.