Hiding multiple elements at once

Here’s a sample that can at least shorten your code and maybe make it more readable -

$w.onReady(function () {
    
});
const b1 = $w("#button1");
const b2 = $w("#button2");
const b3 = $w("#button3");
const b4 = $w("#button4");

function show(btn) {
    btn.show();
    }
function hide(btn) {
    btn.hide();
    }

hide (b2); //for example


I’m sure there’s a way to express multiple element.options in an array-like fashion, but I’m too tired to keep trying stuff out…:expressionless: