draivin / hsnips

HyperSnips: a powerful snippet engine for VS Code, inspired by vim's UltiSnips
MIT License
154 stars 25 forks source link

Second tab placeholder fails #83

Closed hinell closed 2 years ago

hinell commented 3 years ago

Tabs that follow a JS block inside a snippet fail the whole thing to compile. Try to complete the failure as usual - it won't.

snippet failure "" w
$1 
`` rv = '$1 length is ' + (t[0] || '').length + '$2 length is' + (t[1] || '').length)``
$2
endsnippet

Versioning

draivin commented 2 years ago

The compilation issue here is an extra parenthesis at the end of the javascript code block. There was another error related to dollar sign escaping, but that is fixed as of the latest release.