- Add Capacitor core, CLI, and Android platform - Install plugins: camera, push-notifications, splash-screen, status-bar - Configure capacitor.config.ts with app ID run.runfoo.veridian - Update vite.config.ts with base: './' for Capacitor compatibility - Update api.ts and SessionTimeoutWarning.tsx to detect Capacitor and use production API URL - Generate Android project structure with Gradle build files
21 lines
518 B
TypeScript
21 lines
518 B
TypeScript
import { defineConfig } from 'vite'
|
|
import react from '@vitejs/plugin-react'
|
|
import path from 'path'
|
|
import { fileURLToPath } from 'url'
|
|
|
|
const __dirname = path.dirname(fileURLToPath(import.meta.url))
|
|
|
|
// https://vitejs.dev/config/
|
|
export default defineConfig({
|
|
plugins: [react()],
|
|
base: './', // Required for Capacitor - relative asset paths
|
|
resolve: {
|
|
alias: {
|
|
'@': path.resolve(__dirname, './src'),
|
|
},
|
|
},
|
|
server: {
|
|
host: '0.0.0.0',
|
|
port: 80,
|
|
}
|
|
})
|