import Vue from 'vue'

import App from './App.vue'
import { createRouter } from './router'
import { createStore } from './store'

import VueRouter from 'vue-router'
import Vuex from 'vuex'

/* FontAwesome */
import { library } from '@fortawesome/fontawesome-svg-core'
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome'
import { faTrash } from '@fortawesome/free-solid-svg-icons'
import './css/app.css'
import './css/base.css'
import './css/components.css'
import './css/theme.css'

import {
  faBars,
  faAngleDown,
  faMoon,
  faSun,
  faTimesCircle,
  faWater,
  faExternalLinkAlt
} from '@fortawesome/free-solid-svg-icons'

import {
  faTwitter,
  faGithub
} from '@fortawesome/free-brands-svg-icons'


Vue.use(VueRouter)
Vue.use(Vuex)

/* Router + Store */
const store = createStore()
const router = createRouter(store)

/* Fontawesome setup */
library.add(
  faBars,
  faAngleDown,
  faMoon,
  faSun,
  faTimesCircle,
  faWater,
  faExternalLinkAlt,
  faTwitter,
  faGithub,
  faTrash
)

Vue.component('fa-icon', FontAwesomeIcon)

Vue.prototype.$MODE = "client"
Vue.prototype.$config = {}
Vue.prototype.$axios = {}
/* Fix Ads script error */
window.VUE_ENV = 'client'

Vue.config.productionTip = false

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')