Skip to content

chr1974/trongate-sublimetext-snippets

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

trongate-sublimetext-snippets

Some simple Trongate Framework Snippets for sublime text 4 based of off Jakecastelli's trongate-vscode snippets

Contributions Welcome!

Triggers used currently:

tabTrigger Description
tgc Creates a class that extends Trongate
tg:submit Creates a submit function
tg:for Creates a foreach loop in a Viewfile
tg:if Creates a if condition in a Viefile
tg:ifelse Creates a if else condition in a Viewfile

to use the snippets navigate to: C:\Users<your_username>\AppData\Roaming\Sublime Text\Packages\User and add the trongate-snippets folder into that folder.

example snippet

<!-- your snippet goes here, tab positions should be marked ${1}, ${2} and so on... $0 marks where last tabstop ends -->
<!-- for class name default name you can use ${<num>:<default name>} in the tab marker.
<!-- in front of dollarsign on php variables we must put a single \ in front of it like so: \$var  for it to shoa as var in snippet-->
<snippet>
   <content><![CDATA[
      if (${1}) {
        ${2}// do suff if here
      } else {
        ${3} // do other stuff here
      }
   ]]></content>
   <description>Add a description for the snippet, will show in dropdown list</description> <!-- optional (filename as default description if not used) -->
  
   <tabTrigger>add the keyword that triggers the snippet on TAB (us tg:) as prefix and check that it is not in use by the other snippets first.</tabTrigger>
    
   <!-- <scope>source.php</scope> -->
   <!-- optional use source.php if the file already starts with <?php and only php is used in source file, or commet it out if you want it to show in all places --> 
</snippet>

About

Some simple Trongate Framework Snippets for sublime text 4

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published