13204f1baf
modified: main_dc/BB/bbvue/src/main.js modified: main_dc/BB/bbvue/src/views/Profile.vue add links from profile icons to login and logout on header
32 lines
879 B
JavaScript
32 lines
879 B
JavaScript
import './assets/main.css'
|
|
|
|
import { createApp } from 'vue'
|
|
import pinia from './stores'
|
|
|
|
import App from './App.vue'
|
|
import router from './router'
|
|
import WriteLogo from './components/writeLogo.vue'
|
|
import { Icon } from '@iconify/vue'
|
|
|
|
const app = createApp(App)
|
|
|
|
// Регистрируем компоненты глобально
|
|
app.component('WriteLogo', WriteLogo)
|
|
// eslint-disable-next-line vue/multi-word-component-names
|
|
app.component('Icon', Icon)
|
|
|
|
app.use(pinia)
|
|
app.use(router)
|
|
|
|
// Инициализация auth store после создания app
|
|
import { useAuthStore } from './stores/auth'
|
|
const authStore = useAuthStore()
|
|
// Инициализируем авторизацию
|
|
authStore.initializeAuth().then(() => {
|
|
console.log('Auth initialization completed')
|
|
}).catch(error => {
|
|
console.error('Auth initialization failed:', error)
|
|
})
|
|
|
|
app.mount('#app')
|