Sublime Text 2 Comment/Doc Block

Taha picture Taha · Sep 20, 2011 · Viewed 30.5k times · Source

Recently, I decided to try out Sublime Text 2 as a TextMate alternative (which it is). I'm absolutely loving it but the only issue that bugs me is that it doesn't continue the PHP Comment/Doc Block upon pressing "Enter".

It just adds new blank lines instead of lines starting with "* " as seen here http://cl.ly/AFcP/o

Is there a solution to this? I tried doing a key binding for it but it was just too complicated for me, especially because I'm not too experienced with the editor.

Thanks in advance.

Answer

Clint picture Clint · Nov 20, 2011

And now an even better solution has become available:

https://github.com/spadgos/sublime-jsdocs

It is called DocBlockr, and it has PHPDoc support. It automatically adds the doc block based on the function parameters. Nice...