New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

表单元素radio value无法绑定 #66

lyf911010 opened this Issue Mar 13, 2018 · 1 comment


None yet
2 participants

lyf911010 commented Mar 13, 2018

在使用input type=radio时候,编译之后,radio标签中的value值一直为空,不知道如何绑定


This comment has been minimized.


anchengjian commented Mar 13, 2018

建议直接用 radio-group :

    <radio-group class="radio-group" @change="radioChange">
      <label class="radio" v-for="(item, index) in items" :key="">
        <radio :value="" :checked="item.checked"/> {{item.value}}

export default {
  data () {
    return {
      items: [
        {name: 'USA', value: '美国'},
        {name: 'CHN', value: '中国', checked: 'true'},
        {name: 'BRA', value: '巴西'},
        {name: 'JPN', value: '日本'},
        {name: 'ENG', value: '英国'},
        {name: 'TUR', value: '法国'}
  methods: {
    radioChange (e) {



Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment