├── phpstorm_live_templates.png ├── README.md └── templates └── tomas_votruba_php.xml /phpstorm_live_templates.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TomasVotruba/PhpStorm-LiveTemplates/HEAD/phpstorm_live_templates.png -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # My Handy PhpStorm Live Templates 2 | 3 | ![Constructor Live Template](phpstorm_live_templates.png) 4 | 5 | ## Install 6 | 7 | 1. Go to *PhpStorm Preferences | Tools | Settings Repository* 8 | 9 | 2. Add Read-only Source https://github.com/TomasVotruba/PhpStorm-LiveTemplates 10 | 11 | 3. Restart PhpStorm and profit! 12 | 13 | 14 | ## What is in this package? 15 | 16 | #### `st` 17 | 18 | ```php 19 | declare(strict_types=1); 20 | ``` 21 | 22 | #### `ctor` 23 | 24 | ```php 25 | public function __construct($END$) 26 | { 27 | } 28 | ``` 29 | 30 | #### `pub` 31 | 32 | ```php 33 | public function $NAME$($ARGS$) 34 | { 35 | $END$ 36 | } 37 | ``` 38 | 39 | #### `pri` 40 | 41 | ```php 42 | private function $NAME$($ARGS$) 43 | { 44 | $END$ 45 | } 46 | ``` 47 | 48 | #### `vs` 49 | 50 | ```php 51 | /** 52 | * @var string 53 | */ 54 | ``` 55 | 56 | #### `va` 57 | 58 | ```php 59 | /** 60 | * @var string[] 61 | */ 62 | ``` 63 | 64 | #### `vi` 65 | 66 | ```php 67 | /** 68 | * @var int 69 | */ 70 | ``` 71 | 72 | #### `ra` 73 | 74 | ```php 75 | /** 76 | * @return string[] 77 | */ 78 | ``` 79 | -------------------------------------------------------------------------------- /templates/tomas_votruba_php.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 13 | 20 | 27 | 32 | 37 | 43 | 48 | 54 | 55 | --------------------------------------------------------------------------------