<input type="checkbox" name="test_checkbox" :checked1111="test" @click="onClick"> Test
onClick: function (e) {
this.test = e.target.checked
console.log(this.test)
}
You can write whatever you want in checked1111. Strangely enough, the check function can be realized
or written as
<input type="checkbox" name="test_checkbox" :aaafc="test" @click="onClick"> Test
can realize two-way binding of data test
世界只因有你2017-05-19 10:12:52
Because what works is your onClick processing function, you bind whether checked to test in this function, so it is okay if you do not write: checked="test" on the input tag.