updated vue template

This commit is contained in:
Lea Anthony
2019-01-23 08:35:12 +11:00
parent 683ba7dc59
commit 6e011e75c3
5 changed files with 257 additions and 7 deletions
+15
View File
@@ -0,0 +1,15 @@
/*
Wails Bridge (c) 2019-present Lea Anthony
This prod version is to get around having to rewrite your code
for production. When doing a release build, this file will be used
instead of the full version.
*/
export default {
// The main function
// Passes the main Wails object to the callback if given.
Start: function (callback) {
return callback();
}
};
@@ -8,6 +8,7 @@
<script>
import "../assets/css/quote.css";
import { eventBus } from "../main";
export default {
data() {
@@ -24,7 +25,7 @@ export default {
}
},
created() {
this.getNewQuote();
eventBus.$on("ready", this.getNewQuote);
}
};
</script>
+12 -6
View File
@@ -1,8 +1,14 @@
import Vue from 'vue'
import App from './App.vue'
Vue.config.productionTip = false
import Vue from "vue";
export const eventBus = new Vue();
import App from "./App.vue";
new Vue({
render: h => h(App),
}).$mount('#app')
render: h => h(App)
}).$mount("#app");
import Bridge from "./wailsbridge";
Bridge.Start(startApp);
function startApp() {
eventBus.$emit("ready");
}
File diff suppressed because one or more lines are too long
@@ -0,0 +1,15 @@
/*
Wails Bridge (c) 2019-present Lea Anthony
This prod version is to get around having to rewrite your code
for production. When doing a release build, this file will be used
instead of the full version.
*/
export default {
// The main function
// Passes the main Wails object to the callback if given.
Start: function (callback) {
return callback();
}
};