PHP Awesome Snippets - VScode extension
This VScode extension provide a fullset of snippets for PHP devs. It's pretty simple !
You can use it to avoid wasting time typing Class blocks, function signatures or other common PHP statements.
The code generated is as compliant as possible with PSR-1, PSR-2 and PSR-12 (Review stage) coding standards provided by PHP-FIG.
Snippets are PHP7 oriented (type hinting and return type) but PHP5 compatibility is also provided (see Functions and Methods sections).
This work is inspired by PHPstorm (PHP Live Templates) and other works available on VScode marketplace like PHP Snippets VS Code or PHP Snippet Pack.
Type a snippet (or part of it), press
editor.tabCompletion set to
true in your settings) and the snippet will expand just right there.
Tip : Snippets provided in this extension support
tab to next/previous placeholder.
These snippets are meant to work in PHP context (VScode file). However there are also available in Plain Text context for convenience and PHP tags are available in HTML one.
These snippets try to be as intuitive as possible and to avoid conflicts with previous or built-in snippets.
Placeholders are quite 'easy to use' though some need optimizations.
Tip : If you want to use snippets and completion in placeholders
look at the Extension settings section.