0.0.11 • Published 3 years ago

@twoavy/vue-utils v0.0.11

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

@twoavy/vue-utils

Installation

yarn add @twoavy/vue-utils

Usage

import TwoavyUtils from '@twoavy/utils'

in main.js

Vue.use(TwoavyUtils, {
    url: 'http://twoavy.test',
    client_id: 13,
    client_secret: 'b2834basdk8asd278dahb49urf39da',
    logging: true,
    device_id: 5,
    showErrorsOnScreen: true, // directly handle errors and show them on-screen
    ready: initVue, // callback when axios is ready to use
    retries: 3 // number of axios retries before failing
})

// init Vue AFTER axios is set up
function initVue() {
    new Vue({
        store,
        render: h => h(App)
    }).$mount('#app')

in components

// make api calls
this.$axios.get('/dostuff')

// log events
this.$twoavy.log('log_type', 'log_message')
0.0.10

3 years ago

0.0.11

3 years ago

0.0.9

3 years ago

0.0.8

3 years ago

0.0.7

4 years ago

0.0.6

4 years ago

0.0.5

4 years ago

0.0.4

4 years ago

0.0.3

4 years ago

0.0.2

4 years ago

0.0.1

4 years ago