Live templates - providing default values from the template text



I know I can set defaults values with the UI ("Edit Variables"), but any way to do that directly with the syntax in the snippet? For instance:

foo = $bar$ * 2

Let's say I want "bar" to be 42 by default.

1 comment

You can use groovyScript to check the value of the variable passed to the template and set it to something different if not provided:


Please sign in to leave a comment.