CODEX
didSet() and willSet() Methods in Swift
Learn how to automatically trigger actions when properties change.
In Swift, property observers make observations on properties. They get triggered when an observed property changes.
According to Swift Docs:
Property observers observe and respond to changes in a…