Hi I have a project that runs on Vue 2 and will be moved to Vue 3 soon, Before that, I have a POC to check and learn how this vue-composition API works. So the setup and all went really well and no functional issues for the component.
However, I keep getting The setup binding property "XYZ" is already declared for all the data variables that were initialized and are returned at the end of the setup(). If I don't return{} they are not referenced.
Please if anyone can help me fix the issue.
Here is the basic snippet I initially started
import {
ref,
reactive,
} from "@vue/composition-api";
export default {
setup() {
const isLoading = ref(false);
const user = ref('Akash');
}
return{
isLoading,
user
}
}
</script>
I figured that I have the same component that is being loaded in multiple places so are the errors. Have to figure out how to resolve it. Hence closing this issue
Hi I have a project that runs on Vue 2 and will be moved to Vue 3 soon, Before that, I have a POC to check and learn how this vue-composition API works. So the setup and all went really well and no functional issues for the component.
However, I keep getting
The setup binding property "XYZ" is already declared
for all the data variables that were initialized and are returned at the end of thesetup()
. If I don'treturn{}
they are not referenced.Please if anyone can help me fix the issue.
Here is the basic snippet I initially started