-
Notifications
You must be signed in to change notification settings - Fork 472
Using Custom Code Snippets
Roger Hu edited this page Oct 18, 2017
·
2 revisions
When you find yourself using the same pieces of code over and over again, it is often helpful to create a custom Code Snippet!
- Select the Code Snippet Library on the bottom of the Utilities Pane.
- Highlight the code you want to save as a snippet.
- Drag the highlighted code into the Code Snippet Library.
- Give your Custom Snippet a Name.
- Give Your Custom Snippet an easy to remember shortcut.
There are 2 easy ways to access your custom code snippet.
- Type in the shortcut and let Xcode Auto-Complete the rest.
- Drag the snippet into your file directly from the Code Snippet Library.