UNPKG

vue-ant-patterns

Version:

vue-ant-patterns

38 lines (33 loc) 705 B
'use strict'; Object.defineProperty(exports, "__esModule", { value: true }); var VueAxios = { vm: {}, // eslint-disable-next-line no-unused-vars install: function install(Vue, instance) { if (this.installed) { return; } this.installed = true; if (!instance) { // eslint-disable-next-line no-console console.error('You have to install axios'); return; } Vue.axios = instance; Object.defineProperties(Vue.prototype, { axios: { get: function get() { return instance; } }, $http: { get: function get() { return instance; } } }); } }; exports.VueAxios = VueAxios;