<template>
<div class="about">
<h1>This is an about page 1 {{ FirstName }}</h1>
<h2>This is an about page 2 {{ car.name }}</h2>
<h3>This is an about page 3 {{ car.price }}</h3>
<h4>This is an about page 4 {{ obj.key }}</h4>
<button @click="changFirstName">changFirstName</button>
</div>
</template>
<script>
import { reactive, ref } from "vue";
export default {
setup() {
let FirstName = ref("First");
let car = reactive({
name: "Car",
price: 5000
});
let obj = ref({
'key' : 'Test object'
})
function changFirstName() {
car.name = "Car Test";
obj._value.key = "GGGGGGGG 🤣";
this.FirstName = "Abc";
}
return {
FirstName,
car,
obj,
changFirstName
}
}
}
</script>