<script> switch (red) { case 1: { result = 'one'; break; } case 2: case 3: result = 'two'; break; case (var1 === true && var2 === true) : // Do something break; default: result = 'unknown'; } </script>