title: vuejs radio button component
body: <p>I trying to make this custom radio button component to work in vuejs. How do I make the radio button checked with a value from parent component. I know you use v-model and set it to a same value in one of the input values, but it dont seem to get it work.</p>
  
  <p>component: </p>
  
  <pre><code>export default Vue.component('radioButton', {
    template,
    props: ['name', 'label', 'id', 'value']
  })
  </code></pre>
  
  <p>component template:</p>
  
  <pre><code>&lt;label class="radio" :for="id"&gt;
    &lt;input type="radio" :id="id" class="radio-button" :value="value" :name="name"&gt;
     &lt;span class="radio-circle"&gt;
    &lt;/span&gt;
    &lt;span class="radio-circle__inner"&gt;
    &lt;/span&gt;
    &lt;span class="radio-button__label"&gt;{{ label }}&lt;/span&gt;
  &lt;/label&gt;
  </code></pre>
  
  <p>html:</p>
  
  <pre><code>&lt;radio-button name="options" id="option-1" label="1" :value="selectedValue" /&gt;
  &lt;radio-button name="options" id="option-2" label="2" :value="selectedValue" /&gt;
  </code></pre>