Store data in protocol and class extensions
Published in
Nov 16, 2020
Many times I needed to save some data in protocol or class extensions. By default Swift doesn’t allow us to do this, but there is simple workaround using runtime manipulation. If you try add computed property in standard way, You will probably see compile error
Extensions must not contain stored properties