is there any way to make this code simplier?
<b-address
v-model:name="address.name"
v-model:addressLine="address.addressLine"
v-model:streetNumber="address.streetNumber"
v-model:town="address.town"
v-model:country="address.country"
v-model:postcode="address.postcode"
v-model:phoneNumber="address.phoneNumber"
v-model:homeAddress="address.homeAddress"
/>
it would be nice if some shorthand would exist, some like this:
<b-address
v-model="address"
/>
then, since b-address is a component and address is an object, shorthand would be great! any ideas? Thank you
in case the component is not made by you or you do not have the possibility to go and modify that code, nom you cannot :(
if instead, that component is yours, then a hypothesis could be to do v-model:fullAddress giving access to the whole object as a model!
with a result like this
<b-address v-model:fullAddress="address" />