Last active
February 7, 2019 02:04
-
-
Save ajcastro/4a7b4f5c315047b92eec to your computer and use it in GitHub Desktop.
Php class declaration sublime snippet
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<snippet> | |
<content><![CDATA[ | |
<?php | |
namespace ${1:${TM_FILEPATH/(?:.*app\/)|(\/)?([^\/]+)(?=\/)|(?:\/[^\/]+\.php$)/(?1:\\$^N:$^N)/g}}; | |
class ${2:${TM_FILENAME/(.*)[.](.*)/$1/g}} ${3:extends} | |
{ | |
${4:public} function ${5:methodName}($6) | |
{ | |
$7 | |
} | |
} | |
]]></content> | |
<!-- Optional: Set a tabTrigger to define how to trigger the snippet --> | |
<tabTrigger>class</tabTrigger> | |
<!-- Optional: Set a scope to limit where the snippet will trigger --> | |
<!-- <scope>source.php</scope> --> | |
</snippet> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment