1
1
import Vue from 'vue'
2
2
import App from './App.vue'
3
3
import store from "./store" ;
4
- import VueNativeSock from 'vue-native-websocket'
4
+ // use a custom timestamp formatter from this project
5
+ import TimestampFormatter from "./TimestampFormatter" ;
5
6
// use hotkeys for binding keyboard keys to buttons and other components
6
7
import VueHotkey from 'v-hotkey'
7
8
// use Bootstrap for styling
8
9
import BootstrapVue from 'bootstrap-vue'
9
10
import 'bootstrap/dist/css/bootstrap.css'
10
11
import 'bootstrap-vue/dist/bootstrap-vue.css'
11
- import TimestampFormatter from "./TimestampFormatter" ;
12
+ // Use fontawesome to load some icons
13
+ import { library } from '@fortawesome/fontawesome-svg-core'
14
+ import { faCaretSquareDown , faCaretSquareUp , faEdit } from '@fortawesome/free-solid-svg-icons'
15
+ import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome'
16
+ // Connect to the backend with a single websocket that communicates with JSON format and is attached to the store
17
+ import VueNativeSock from 'vue-native-websocket'
18
+
19
+ Vue . use ( TimestampFormatter ) ;
12
20
13
21
Vue . use ( VueHotkey ) ;
22
+
14
23
Vue . use ( BootstrapVue ) ;
15
- Vue . use ( TimestampFormatter ) ;
24
+
25
+ library . add ( faEdit ) ;
26
+ library . add ( faCaretSquareDown ) ;
27
+ library . add ( faCaretSquareUp ) ;
28
+ Vue . component ( 'font-awesome-icon' , FontAwesomeIcon ) ;
16
29
17
30
export let isInNormalHalf = function ( state ) {
18
31
return state . stage === 'First Half' ;
@@ -27,7 +40,6 @@ if (process.env.NODE_ENV === 'development') {
27
40
wsAddress = 'ws://' + window . location . hostname + ':' + window . location . port + '/api/control' ;
28
41
}
29
42
30
- // Connect to the backend with a single websocket that communicates with JSON format and is attached to the store
31
43
Vue . use ( VueNativeSock , wsAddress , {
32
44
reconnection : true ,
33
45
format : 'json' ,
0 commit comments