New AppCode 2016.2 EAP brings Introduce Variable refactoring and argument placeholders for Swift!
New AppCode 2016.2 EAP is available for download with new great features on board! As usual, the patch update is also available if you are using previous 2016.2 EAP build.
This build brings one of the most important features from our roadmap – initial implementation of Introduce Variable refactoring for Swift. Let’s see how you can use it:
- Select the expression you want to extract and press
⌘⌥V. AppCode will suggest the name automatically – you can use it or write your own:
- By default AppCode will extract the constant using
let. Select Declare with ‘var’ option to convert it to the variable:
- You can also specify the type of extracted expression automatically using Specify type explicitly option:
- In case there are several possible expressions to extract, choose the one you need from the list:
- Choose if you want to replace all occurrences of the selected expression or only the single one:
Please, note, that some major issues related to this feature still exist (see subtasks in the base ticket). In case you find any other issue or have any suggestion, please log it as a bug-report or feature request in our tracker.
Completion for function parameter names with corresponding placeholders for arguments is one of the essential IDE features in iOS/OSX world. Starting with this build it is also available in AppCode for Swift language:
- Argument placeholders and parameter names are now inserted automatically for any function or method including initializers:
- You can navigate between parameters forward and back using
Some features related to argument placeholders such as completion for closures are in progress and we will try to deliver them before 2016.2 release.
That’s it! Download the build, try it right now and let us know what you think!
Your AppCode team
The Drive to Develop