Is there a way to insert PHPDoc in VIM using a command or key combination?
For example, I have a class:
class MyClass
{
public function __construct()
Assume you place your template at ~/templates/phpdoc.php.
With the below abbreviation, if you type ,p
, you will
read the contents of your phpdoc.php into the current file,
( at or below the current line - one of those ).
map ,p :r ~/templates/phpdoc.php
Then just add the line to your .vimrc file, replacing the
file-path and ,p
to your liking.