import './assets/main.css';

import { MotionPlugin } from '@vueuse/motion';
import { createApp } from 'vue';
import VueMobileDetection from 'vue-mobile-detection'

import App from './App.vue';
import router from './router';


const app = createApp(App);
app.use(router);
app.use(VueMobileDetection);
app.use(MotionPlugin);
app.mount('#app');

if ('serviceWorker' in navigator) {
    navigator.serviceWorker.register('/sw.js?v=2')
        .then(() => console.log('✅ Service Worker registered'))
        .catch(
            err => console.error('⚠️ Service Worker registration failed:', err));
}