11import Vue from 'vue'
22import App from './App.vue'
33import store from "./store" ;
4- import VueNativeSock from 'vue-native-websocket'
4+ // use a custom timestamp formatter from this project
5+ import TimestampFormatter from "./TimestampFormatter" ;
56// use hotkeys for binding keyboard keys to buttons and other components
67import VueHotkey from 'v-hotkey'
78// use Bootstrap for styling
89import BootstrapVue from 'bootstrap-vue'
910import 'bootstrap/dist/css/bootstrap.css'
1011import '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 ) ;
1220
1321Vue . use ( VueHotkey ) ;
22+
1423Vue . 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 ) ;
1629
1730export let isInNormalHalf = function ( state ) {
1831 return state . stage === 'First Half' ;
@@ -27,7 +40,6 @@ if (process.env.NODE_ENV === 'development') {
2740 wsAddress = 'ws://' + window . location . hostname + ':' + window . location . port + '/api/control' ;
2841}
2942
30- // Connect to the backend with a single websocket that communicates with JSON format and is attached to the store
3143Vue . use ( VueNativeSock , wsAddress , {
3244 reconnection : true ,
3345 format : 'json' ,
0 commit comments