Last active
September 22, 2017 05:35
-
-
Save rednebmas/178fd50026094c67ada457cf625c1c2d to your computer and use it in GitHub Desktop.
My user defined code snippets for ObjC dev in Xcode
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // completion shortcut: @propstrong | |
| @property (nonatomic, strong) <#type#> *<#name#>; | |
| // completion shortcut: @propweak | |
| @property (nonatomic, weak) <#type#> *<#name#>; | |
| // completion shortcut: @propassign | |
| @property (nonatomic, assign) <#type#> <#name#>; | |
| // completion shortcut: dispatch_async | |
| dispatch_async(dispatch_get_main_queue(), ^{ | |
| <#code#> | |
| }); | |
| // completion shortcut: __weakSelf | |
| __weak typeof(self) weakSelf = self; | |
| // completion shortcut mnoparams | |
| - (<#void#>)<#methodName#> { | |
| <#code#> | |
| } | |
| // completion shortcut moneparam | |
| - (<#void#>)<#methodName#>:(<#Type#> *)<#paramName#> { | |
| <#code#> | |
| } | |
| // completion shortcut mtwoparams | |
| - (<#void#>)<#methodName#>:(<#Type#> *)<#paramName#> <#methodName#>:(<#Type#> *)<#paramName#> { | |
| <#code#> | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment