Using VUE 2.0 and VUEX I am a bit confused about how to pass data from parent
to child
.
<template>
<div id="app" class="container">
<div class="card" v-for="(triad, index) in triads">
<div class="row">
<div class="col-sm-4">
<people />
</div>
<div class="col-sm-4">
<places />
</div>
<div class="col-sm-4">
<equipment />
</div>
</div>
</div>
</div>
</template>
I am looping through an array named "triads":
state: {
triads: [
{
people: [],
places: [],
equipment: []
}
]
}
I want to send the triad
variable to <people />
, <places />
and <equipment />
.
How do I get the content from the parent template to the child template? Thank you.