LoginSignup
0
0

More than 3 years have passed since last update.

ionic ui componentで、inputのデータバインドがうまくいかない時(v-modelが効いてない時)

Last updated at Posted at 2021-01-09

覚書です。

<ion-item>
        <ion-label position="stacked">名前</ion-label>
        <ion-input v-model="petName"></ion-input>
</ion-item>

これを
こうすると動く

<ion-item>
        <ion-label position="stacked">名前</ion-label>
        <ion-input :value="petName" @input="petName = $event.target.value"></ion-input>
</ion-item>

参照元🙏:
https://www.koatech.info/blog/vue-databinding-ionic/
https://github.com/vuejs/vue/issues/7830

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0