[TxMt] Snippet’s $variables in RegExp

riddle riddlu at gmail.com
Sun May 18 13:18:58 UTC 2008

Hi, I’m trying to use ${5:helper text} variable in my regular expression
later in the code:


What I do here? I check if $5 equals "e" and if it does, I append
".preventDefault();" to my "e". But I’d like to write something like this:


Which simply means I’d like users to be able to change "e" into, for example

My whole snippet, for better understanding:

bind('${1:event name}'${2:, ${3:passed object}}, function(${4:e}) {

View this message in context: http://www.nabble.com/Snippet%E2%80%99s-%24variables-in-RegExp-tp17302873p17302873.html
Sent from the textmate users mailing list archive at Nabble.com.

More information about the textmate mailing list