From 03aaa4f82fbc171d2f2f977d93f244cacc207a0b Mon Sep 17 00:00:00 2001 From: moon Date: Fri, 11 Oct 2024 01:14:36 -0700 Subject: [PATCH] fix the probs --- src/main.tsx | 2 +- vite.config.ts | 34 ++++------------------------------ 2 files changed, 5 insertions(+), 31 deletions(-) diff --git a/src/main.tsx b/src/main.tsx index 67d17c4..e330abd 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -318,7 +318,7 @@ const App = () => { left: 0, width: '100%', height: '100%', - backgroundImage: 'url(/bg.jpg)', + backgroundImage: 'url(./bg.jpg)', backgroundSize: 'cover', backgroundPosition: 'center', zIndex: -1000, diff --git a/vite.config.ts b/vite.config.ts index d7d1bbe..ce22ed1 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -1,34 +1,8 @@ -/// -/// - -import { resolve } from 'node:path' - import react from '@vitejs/plugin-react' import { defineConfig } from 'vite' -export default defineConfig(async () => ({ - plugins: [react()], +// https://vitejs.dev/config/ +export default defineConfig({ base: '/RubyLive/', - define: { 'import.meta.env.APP_VERSION': `"${process.env.npm_package_version}"` }, - clearScreen: false, - server: { port: 1420, strictPort: true }, - envPrefix: ['VITE_'], - resolve: { - alias: [ - { find: '@', replacement: resolve(__dirname, 'src') }, - { find: '~', replacement: resolve(__dirname, 'public') }, - ], - }, - build: { - emptyOutDir: true, - chunkSizeWarningLimit: 1200, - reportCompressedSize: false, - outDir: resolve(__dirname, 'dist'), - }, - test: { - globals: true, - environment: 'jsdom', - cache: { dir: './node_modules/.vitest' }, - include: ['./**/*.{test,spec}.{ts,tsx}'], - }, -})) + plugins: [react()], +})