Reading the documentation is always a good way to start. In doc/xpt.snippet.syn.txt you'll see details on the syntax of their template files.
A snippet file looks like this : >
XPTemplate priority=lang keyword=$ | |xpt-snippet-header|
let s:f = XPTfuncs() | |xpt-snippet-function|
XPTvar $TRUE true | |xpt-snippet-variable|
XPTvar $FALSE false |
XPTvar $NULL null |
XPTvar $UNDEFINED undefined |
|
XPTvar $CL /* |
XPTvar $CM * |
XPTvar $CR */ |
|
XPTinclude | |xpt-snippet-XPTinclude|
\ _common/common |
\ _comment/doubleSign |
\ _condition/c.like |
fun! s:f.js_filename() | |xpt-snippet-function|
return expand( "%" ) |
endfunction |
XPTemplateDef | |XPTemplateDef|
XPT cmt hint=/**\ @auth...\ */ | |xpt-snippet|
XSET author=$author | |xpt-snippet-XSET|
XSET email=$email | |xpt-snippet-XSET|
/** |\
* @author : `author^ | `email^ | \
* @description | +|xpt-snippet-body|
* `cursor^ | /
* @return {`Object^} `desc^ |/
*/
XPT for hint=for\ (var..;..;++)
...
I personally prefer NerdSnippets which has a very simple snippet template syntax.