Mirroring and Reflection in Swift

Reflection: Is a form of meta programming that allows you to extract information from data structure in runtime

Swift’s version of reflection enables us to iterate over, and read the values of, all the stored properties that a type haswhether that’s a struct, a class, or any other type — enabling a sort of meta programming that can enable us to write code that actually interacts with the code itself.


There is a Mirror struct, if you call on an object, it will give you an idea if it is class, struct, enum, tuple. But it does not work on all types for example closures. If it can not tell you what the type is, it will return nil.

There is a child property which has label and values. You can recursively go through the properties of a data structure and be able to sort of go down in a tree and really to figure out everything that is going on.

Swift 4 Skeleton Project

Hey everyone!

Here is skeleton project for our swift projects with mvc, shared folders and some objective C libraries(for UI animations- ProgressHUD etc.)

This project is also base of angela yu’s project!



Alsoo, here is common auto layout issues both programmatically and Main Board Solutions:



Best Book(s) Ever!

Dear All,

If you are interested in not just codding but not repeating your code in any where, I must recoomend ou to read Rob Martin. Uncle Bob, is the man who taught me what OOP really does. Mainly Solid, and not writing the same things n times instead calling the same method or whatever n times, you must read Clean Code. Then, Clean Coder. Tha language is pretty simple for everyone to understand!
you may easily find the book in amazon!