add nginx config in README

This commit is contained in:
Stefan Dej committed 2020-04-14 13:34:32 +02:00
1 parent beba547031
commit ec827bbea4
4 files changed
+89 -37

No files matched your search

+4 -4
View File
@@ -29,18 +29,18 @@
methods: {
setValue() {
if (this.value) {
let index = this.hiddenMacros.indexOf(this.name);
let index = this.hiddenMacros.indexOf(this.name.toUpperCase());
if (index > -1) this.hiddenMacros.splice(index, 1);
} else this.hiddenMacros.push(this.name);
} else this.hiddenMacros.push(this.name.toUpperCase());
}
},
watch: {
hiddenMacros: function() {
this.value = !this.hiddenMacros.includes(this.name);
this.value = !this.hiddenMacros.includes(this.name.toUpperCase());
}
},
created() {
this.value = !this.hiddenMacros.includes(this.name);
this.value = !this.hiddenMacros.includes(this.name.toUpperCase());
}
}
</script>
+23 -25
View File
@@ -20,29 +20,27 @@ Vue.http.headers.common['Access-Control-Allow-Methods'] = 'POST, GET, PUT, OPTIO
Vue.component('vue-headful', vueHeadful);
fetch('/config.json').then(res => res.json()).then(file => {
store.commit('setSettings', file);
fetch('/config.json').then(res => res.json())
.then(file => {
store.commit('setSettings', file);
Vue.use(JRPCWS, 'ws://' + store.state.socket.hostname + ':' + store.state.socket.port + '/websocket', {
store: store,
reconnectEnabled: true,
reconnectInterval: store.state.socket.reconnectInterval,
reconnectAttempts: store.state.socket.reconnectAttempts,
});
Vue.use(JRPCWS, 'ws://' + store.state.socket.hostname + ':' + store.state.socket.port + '/websocket', {
store: store,
reconnectEnabled: true,
reconnectInterval: store.state.socket.reconnectInterval,
reconnectAttempts: store.state.socket.reconnectAttempts,
});
new Vue({
data(){
return file
},
vuetify,
router,
store,
render: h => h(App)
}).$mount('#app')
}).catch((error) => {
let p = document.createElement("p");
let content = document.createTextNode("config.json not found or cannot be decoded!");
p.appendChild(content);
document.getElementById('app').append(p);
window.console.error('Error:', error);
});
new Vue({
vuetify,
router,
store,
render: h => h(App)
}).$mount('#app')
})
.catch((error) => {
let p = document.createElement("p");
let content = document.createTextNode("config.json not found or cannot be decoded!");
p.appendChild(content);
document.getElementById('app').append(p);
window.console.error('Error:', error);
});
+1 -1
View File
@@ -12,7 +12,7 @@ export default new Vuex.Store({
state: {
socket: {
hostname: window.location.hostname,
port: 8080,
port: window.location.port,
reconnectInterval: 3000,
reconnectAttempts: 1000,
isConnected: false,