How to leave a radiobutton marked as default on Ember

Asked

Viewed 90 times

2

I have these two Components radio-button. I’d like to leave the Pessoa Física marked/checked as default. How do I do this in Emberjs ?.

<div>
  <label>Pessoa Física</label>
  {{radio-button
    id="classificacao-pessoa-is-fisica"
    radioClass="classificacao-pessoa-is-fisica" 
    groupValue=classificacao.pessoa.tipo
    value='FISICA'
  }}
</div>
<div  class="col-sm-12 text-right">
  <label>Pessoa Jurídica</label>
  {{radio-button
    id="classificacao-pessoa-is-juridica"
    radioClass="classificacao-pessoa-is-juridica"
    groupValue=classificacao.pessoa.tipo
    value='JURIDICA'
  }}
</div>

2 answers

2


0

Try to add

checked="checked"

just on the radio you want

  • not sure, an error appears in the console, I was able to set default value in javascript only

Browser other questions tagged

You are not signed in. Login or sign up in order to post.