REAPERAudio Production Without Limits
About : Download : Purchase : Manual : Forum : Resources : REAPER Radio!
REAPER/JS Basic Code Reference

[Back to the main JS programming reference]

The code in the code sections is a simple language that has similarties to C. Some basic features of this language are:

Basic operators:

Some key notes about the above:
  • ( and ) are used to override default precedence, or to enclose multiple statements. For example:
    • x = (y+1)*5;
    • (a = 5; b = 3; );
  • Branching is done using the ? operator, rather than if()/else. For example:
    • a < 5 ? b=1; // if a is less than 5 then set b to 1.
    • a < 5 ? b=1 : c=1; // if a is less than 5 set b to 1, otherwise set C to 1.
    • a < 5 ? ( b=1; c=1; ); // if a is less than 5 set b and c to 1.


Basic math functions:


There are also many
advanced functions.