JavaScript
ECMAScript6

NOTE: NodeList に NodeList の連結と forEach 処理

Concat nodelists and use forEach method

referred from Stack Overflow

unactivate([...tabs, ...codes]);

activate([tab, code]);

function activate(elms) {
Array.prototype.forEach.call(elms, function(elm) {
elm.classList.add(CLASS_NAMES.ACTIVE);
})
}
function unactivate(elms) {
Array.prototype.forEach.call(elms, function(elm) {
elm.classList.remove(CLASS_NAMES.ACTIVE);
});
}