I want to create a fragment at startup, it will surround the given text. Currently, my snippet:
{
"Function Creator Helper": {
"prefix": "_w",
"body": [
"public function $TM_SELECTED_TEXT () {",
" $1",
"}",
],
"description": "Creates a function given the text selection"
}
}
It leads to:

What I am doing is:
- Select the text.
- Write the prefix (
_w) - Press tab
It leads to:
public function () {
}
But I was expecting
public function person () {
}
Any ideas on how I can make this snippet, or how I ran it correctly?
source
share