<ul class="header_navmenu">
<li class="nav_menu-item" v-bind:class="{opacity_deactivated:isActive}"><a href="" target="_blank">1</a></li>
<li class="nav_menu-item" v-bind:class="{opacity_deactivated:isActive}"><a href="">2</a></li>
<li class="nav_menu-item" v-bind:class="{opacity_deactivated:isActive}"><a href="">3</a></li>
<li class="nav_menu-item" v-bind:class="{opacity_deactivated:isActive}"><a href="">4</a></li>
<li class="nav_menu-item" v-bind:class="{opacity_deactivated:isActive}"><a href="">4</a></li>
<li class="nav_menu-item" v-bind:class="{opacity_deactivated:isActive}"><a href="">5</a></li>
</ul>
var app = new Vue({
el: '#header',
data:{
isActive: true
}
})
.hidden {
opacity: 0;
}
data: () => ({
items: [
{ text: '...', hidden: true },
{ text: '...', hidden: true },
...
],
}),
mounted() {
this.items.forEach((n, i) => {
setTimeout(() => n.hidden = false, 300 * (i + 1));
});
},
<li v-for="{ text, hidden } in items" :class="{ hidden }">
<a href="">{{ text }}</a>
</li>