Browse Source

first commit

twt 2 years ago
commit
1b7db09be9
1 changed files with 34 additions and 0 deletions
  1. 34 0
      main.js

+ 34 - 0
main.js

@@ -0,0 +1,34 @@
+import App from './App'
+
+// #ifndef VUE3
+import Vue from 'vue'
+Vue.config.productionTip = false
+App.mpType = 'app'
+
+
+import signature from 'utils/signature.js'
+import store from './store'
+Vue.prototype.$store = store // 定义成全局组件
+import request from 'utils/request.js'
+Vue.prototype.$http = request.http
+Vue.prototype.$fetchPost = request.fetchPost
+Vue.prototype.$baseURL = request.baseURL
+Vue.prototype.$getHashQuery=signature.getHashQuery
+
+const app = new Vue({
+    ...App
+})
+app.$mount()
+// #endif
+
+// #ifdef VUE3
+
+
+
+export function createApp() {
+  const app = createSSRApp(App)
+  return {
+    app
+  }
+}
+// #endif