var

fun var(name: String, value: Dynamic): Void

Defines a new variable or overwrites an existing one.

.var {myvar} {0}

Variables can be referenced just like functions:

The variable has value .myvar

Variables can be reassigned in two ways:

  • By calling the variable as a function with one argument, which is the new value to assign:

.myvar {42}
  • By calling this var function again:

.var {myvar} {42}

Parameters

name

name of the variable

value

value to assign

Wiki page

Variables