Vue class based components

Save time while coding with class-based approach for vue


This project features:

Make your code look like this:

import { Vue, Component, Prop, Watch, Emit, Ref } from 'vue-property-decorator'

@Component
export class MyComp extends Vue {

  @Ref
  button: HTMLInputElement;

  @Prop() readonly propA!: number;

  @Watch('child')
  onChildChanged(val: string, oldVal: string) { }

  @Emit()
  changedProps() {}
}

Clone this repo akoidan/vue3-vite-vue-class-component and check the docs there