Open SergioFaya opened 2 years ago
Any news on v8.0 documentation?
As I understand vue3 is far from being supported at all. Using this example: package.json:
{
"vue-class-component": "https://github.com/vuejs/vue-class-component#next"
}
<template>
<div>{{ count }}</div>
<button @click="increment">+1</button>
</template>
<script lang="ts">
import {Options, Vue} from 'vue-class-component'
@Options({})
export default class Counter extends Vue {
count = 0
increment() {
this.count++
console.log('as')
}
decrement() {
this.count--
}
}
</script>
rm -rf node_modules && \
yarn install && \
cd node_modules/vue-class-component && \
yarn install && \
yarn build && \
cd ../..
property count is not reactive. Upon pressing a button it stil shows 0
As a new Vue developer, I chose to start using vue-cli with typescript and vue-class-component. But when I started the project there was no @Component annotation on the classes but a @Options one.
After further investigating I discovered that this is a feature added for the Vue3 version but on the home page the Vue2 explanations are shown. Would be necessary to provide more comprehensive docs regarding the differences between the maintained versions like shown in here