I have this
<f7-list form>
<!-- Textarea -->
<f7-list-item>
<f7-input type="textarea" placeholder="Default address" id="address"></f7-input>
</f7-list-item>
</f7-list>
<!-- Button Nex -->
<f7-block>
<f7-button class="" value="1" id="btnPageAdress" href="/step1/">Next</f7-button>
</f7-block>
<script>
export default {
}
}
</script>
And I need to send data (address) from textarea to server on button click (#btnPageAdress). (I just started to learn Vue, and tried to google it, but or something that does not fit or complex options) Can someone help me?
I found [https://jsfiddle.net/sh70oe4n/]
and i do this
<f7-block id="addressBox">
<f7-list form id="address-form">
<!-- Textarea -->
<f7-list-item>
<f7-input type="textarea" placeholder="Default address" id="address" ref="addressArea"></f7-input>
</f7-list-item>
</f7-list>
<!-- Button Nex -->
<f7-block>
<f7-button class="" value="1" id="btnPageAdress" href="#" @click.prevent="getFormValues()">Next</f7-button>
</f7-block>
</f7-block>
In Vue.js
// My Vue JS
new Vue({
el: '#addressBox',
data: {
address: ''
},
methods: {
getFormValues () {
this.address = this.addressArea.value,
console.log(this.address)
}
}
})
But still does not work