Hello everyone, I recently started using Vue and I'm trying to achieve the following goal.
I have a form with some data and a save button. Before the page fully loads, it needs to fetch data from the database and pre-fill the form. The save button should initially be disabled because all the data is already filled. Only when the user makes changes to the form, the save button should become enabled and allow the user to save the changes.
I understand that I should be using the watch property, but I'm not sure how to actually implement this. Any guidance would be greatly appreciated!
The structure of the form data looks like this:
data(){
return {
form: {
firstName: "",
lastName: ""
}
}
}