vue-class
TypeScript icon, indicating that this package has built-in type declarations

2.0.1 • Public • Published

Vue Class

Decorator for building Vue2 & TypeScript2 Component.

Install

npm

npm i vue-class --save

yarn

yarn add vue-class

Usage

app.ts

import render from './app.html';
import { Vue, Component, Watch } from 'vue-class';
 
@Component({
   render,
   name: 'app',
   props: ['value']
})
class App extends Vue {
   value: number;
 
   @Watch('value')
   onValueChange(value: number): void {
      console.log(value);
   }
}

Dependences

Readme

Keywords

none

Package Sidebar

Install

npm i vue-class

Weekly Downloads

29

Version

2.0.1

License

ISC

Unpacked Size

4.9 kB

Total Files

9

Last publish

Collaborators

  • chenjiahan
  • niksun
  • zsky