Introduce script di sviluppo concorrenti (frontend + server) con concurrently. Aggiorna dipendenze lockfile e rimuove dipendenze non più necessarie. Aggiunge configurazione server/proxy Vite e include plugin WebSocket dedicato.
47 lines
1002 B
JavaScript
47 lines
1002 B
JavaScript
import { defineConfig } from 'vite'
|
|
import vue from '@vitejs/plugin-vue'
|
|
import { VitePWA } from 'vite-plugin-pwa'
|
|
|
|
// Configurazione principale di Vite
|
|
export default defineConfig({
|
|
base: '/',
|
|
plugins: [
|
|
vue(),
|
|
VitePWA({
|
|
registerType: 'autoUpdate',
|
|
manifest: {
|
|
name: "app_segnap",
|
|
short_name: "segnap",
|
|
description: "Segnapunti standalone.",
|
|
background_color: "#eee",
|
|
theme_color: '#ffffff',
|
|
display: "fullscreen",
|
|
orientation: "landscape",
|
|
icons: [
|
|
{
|
|
src: 'segnap-192x192.png',
|
|
sizes: '192x192',
|
|
type: 'image/png'
|
|
},
|
|
{
|
|
src: 'segnap-512x512.png',
|
|
sizes: '512x512',
|
|
type: 'image/png'
|
|
}
|
|
]
|
|
}
|
|
})
|
|
],
|
|
server: {
|
|
host: '0.0.0.0',
|
|
port: 5173,
|
|
proxy: {
|
|
'/': {
|
|
target: 'http://127.0.0.1:5174',
|
|
ws: true,
|
|
changeOrigin: true,
|
|
},
|
|
},
|
|
},
|
|
})
|