This commit is contained in:
syuilo 2018-02-09 18:57:42 +09:00
parent b7596e357c
commit d5f345c8f9
2 changed files with 8 additions and 16 deletions

View File

@ -5,9 +5,7 @@
// Style // Style
import './style.styl'; import './style.styl';
require('./tags'); import Vue from 'vue';
require('./mixins');
import * as riot from 'riot';
import init from '../init'; import init from '../init';
import route from './router'; import route from './router';
import fuckAdBlock from './scripts/fuck-ad-block'; import fuckAdBlock from './scripts/fuck-ad-block';
@ -18,7 +16,7 @@ import composeNotification from '../common/scripts/compose-notification';
/** /**
* init * init
*/ */
init(async (mios: MiOS) => { init(async (mios: MiOS, app: Vue) => {
/** /**
* Fuck AD Block * Fuck AD Block
*/ */

View File

@ -13,7 +13,6 @@ import VueRouter from 'vue-router';
Vue.use(VueRouter); Vue.use(VueRouter);
import checkForUpdate from './common/scripts/check-for-update'; import checkForUpdate from './common/scripts/check-for-update';
import mixin from './common/mixins';
import MiOS from './common/mios'; import MiOS from './common/mios';
/** /**
@ -64,20 +63,15 @@ export default (callback, sw = false) => {
const mios = new MiOS(sw); const mios = new MiOS(sw);
mios.init(() => { mios.init(() => {
// ミックスイン初期化
mixin(mios);
// ローディング画面クリア
const ini = document.getElementById('ini');
ini.parentNode.removeChild(ini);
// アプリ基底要素マウント // アプリ基底要素マウント
const app = document.createElement('div'); document.body.innerHTML = '<div id="app"><router-view></router-view></div>';
app.setAttribute('id', 'app');
document.body.appendChild(app); const app = new Vue({
router: new VueRouter()
}).$mount('#app');
try { try {
callback(mios); callback(mios, app);
} catch (e) { } catch (e) {
panic(e); panic(e);
} }