Implement some flow and cleanup API call for file manager
This commit is contained in:
parent
c3ef290145
commit
aee42df3ad
9 changed files with 186 additions and 118 deletions
|
@ -1,3 +1,4 @@
|
|||
// @flow
|
||||
import Vue from 'vue';
|
||||
import Vuex from 'vuex';
|
||||
import vuexI18n from 'vuex-i18n';
|
||||
|
@ -14,7 +15,7 @@ import { flash } from './mixins/flash';
|
|||
import store from './store/index.js';
|
||||
import router from './router';
|
||||
|
||||
window.events = new Vue;
|
||||
window.events = new Vue();
|
||||
window.Ziggy = Ziggy;
|
||||
|
||||
Vue.use(Vuex);
|
||||
|
@ -22,16 +23,18 @@ Vue.use(VueRouter);
|
|||
Vue.use(vuexI18n.plugin, store);
|
||||
Vue.use(VeeValidate);
|
||||
|
||||
// $FlowFixMe: this is always going to be unhappy because we ignore the vendor dir.
|
||||
const route = require('./../../../vendor/tightenco/ziggy/src/js/route').default;
|
||||
|
||||
Vue.mixin({ methods: { route } });
|
||||
Vue.mixin({ methods: { route }});
|
||||
Vue.mixin(flash);
|
||||
|
||||
Vue.i18n.add('en', Locales.en);
|
||||
Vue.i18n.set('en');
|
||||
|
||||
// $FlowFixMe
|
||||
if (module.hot) {
|
||||
module.hot.accept();
|
||||
}
|
||||
|
||||
const app = new Vue({ store, router }).$mount('#pterodactyl');
|
||||
new Vue({ store, router }).$mount('#pterodactyl');
|
||||
|
|
Reference in a new issue