Code Snippet Library
You may have noticed that when you start typing the word init, Xcode will automatically add an init implementation in your source file. If you haven’t noticed this, go ahead and type init in an implementation file and wait for the code-completion to kick in.
The freebie code comes from the code snippet library. You can see the code snippet library by opening
the utilities area and selecting the
icon in the library selector (Figure 10.13).
Alternatively, you can use the shortcut Command-Control-Option-2,
which reveals the utilities area and the Code Snippet Library. Substituting another number in the shortcut selects the corresponding ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access