@@ -6,6 +6,7 @@
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
<title>训练态势大屏</title>
+ <script type="text/javascript" src="static/config.js"></script>
</head>
<body>
<noscript>
@@ -0,0 +1,6 @@
+window.config = {
+ webSocket: {
+ url: "localhost",
+ port: "8084"
+ }
+}
@@ -4,7 +4,10 @@ import Vuex from "vuex";
Vue.use(Vuex);
export default new Vuex.Store({
- state: {},
+ state: {
+ webSocketIp: window.config.webSocket.url,
+ webSocketPort: window.config.webSocket.port
+ },
mutations: {},
actions: {},
modules: {},