Clicky

iOS Dev Nugget 230 Shortcut to Generate Quick Help Documentation

.

Need to run a code review on your codebase? Hire me

Hitting cmd+opt+/ in Xcode while the cursor is on a type or function declaration will generate a quick help documentation for you. E.g.

With a function like this:

func foo(name: String) -> Int {}

This is generated:

/// Description
///
/// - Parameter name: name description
/// - Returns: return value description

Works with both Swift and Obj-C.

PS: This shortcut might already be used by another app. E.g. Alfred uses this for one of it's shortcuts. It's available via Editor > Structure > Add Documentation, so you can reassign a different shortcut.


Your feedback is valuable: Do you want more nuggets like this?   Yes   or   No

.

.

Like this and want such iOS dev nuggets to be emailed to you, weekly?

Sign Me Up! or follow @iosdevnuggets on Twitter

.

View archives of past issues