Cannot get tab stops which include choices
Opened this issue · 0 comments
Mark-hub-work commented
I'm not sure if hypersnips is supposed to allow for this or not but in the VSCode snippets you can add choices or placeholders to your tab stops like this:
snippet hypertest "Will let you echo a field"
echo \$fields->render_field('${1:field_name}'
[
'type' => '${2|accordion,alignment_matrix,angle_picker,border,button_group,checkbox,color_picker,combo_box,date_picker,dimensions,field_group,file,gallery,gradient,hidden,number,radio,select,simple_dimension,switch,text,text_suggestion,textarea,wysiwyg'|}',
``rv= `field 1 has ${t[0].length} characters!` ``
endsnippet
But if I try to get the length of either of these tab stops their length will be 0. If I try to get the text from the tab stops they will be empty. If I change them to $1 and $2 they will work as intended.
So does hypersnips not support these kind of tab stops, or do you access them using some other syntax?