Automatically add triple slash on new line

Hi folks,


I am looking for a way to automatically add triple slashes ("///") while I am editing code documentation (see HeaderDoc) in Xcode.

It as annoying that whenever I hit return within the code documentation block for a new line, I firstly have to type "///".


Is there any way to automatically detect the documentation block and add "///" to the next line?


Thanks!

There is a shortcut opt-cmd/ defined in XCode


But for me it conflicts with breakpoint setting.

Agree, this is the shortcut to add the standard comment block.

However, my use case rather refer to the fact that the standard comment block has been created already and one want to add more lines to this comment block (e.g. adding a section for "Discussion").

Not sure I see the case without an example.


have you tried code snippets in IB ?

Automatically add triple slash on new line
 
 
Q