Vue Component Extra Created Hook and Methods Event

vue-track-ve

add vue component extra created hook and methods event

The vue component adds additional created hooks and additional methods to handle page access and click events separately

Isolate specific businesses from manual reporting requirements

Instructions

npm i vue-track-ve -s

Introduce

import Vue from 'vue'
import VueTrackVe from 'vue-track-ve'
Vue.use(VueTrackVe)

Within the component

export default {
    $track:{
        $view(){

        },
        onHandle(){

        }
    }
}

ts

main.ts

import { Component } from 'vue-property-decorator';

Component.registerHooks(['$track'])

component

$track(){
      return {
        $view(){

        },
        onHandle(){

        }
      }
    }

Description: The $view and created hooks in the track object are the same

Others are functions in methods, such as

onHandle is actually onHandle in methods, but onHandle is just a function of click events, don’t deal with business logic here

Download Details:

Author: wut1

Source Code: https://github.com/wut1/vue-track

#vue #vuejs #javascript

Vue Component Extra Created Hook and Methods Event
10.20 GEEK