December 2018
Intermediate to advanced
414 pages
10h 19m
English
The builder pattern is one of the best examples for getting started with metaprogramming. Sourcery can help us generate the code, and we'll quickly see how it is possible to add a simple builder stencil.
Sourcery is a command-line tool, quite popular in the Swift community, that can help you generate code. I recommend you take some time to read the documentation as well as digging into the tutorials.
First, you will need to install Sourcery on your machine. There are multiple methods, but the best way is to follow the instructions at https://github.com/krzysztofzablocki/Sourcery#installation.
My preferred method would be to install it with Homebrew.
Once you have Sourcery, you can familiarize ...
Read now
Unlock full access