Import the existing local project snapshot. This commit organizes existing files; it does not represent newly developed functionality.
35 lines
955 B
JavaScript
35 lines
955 B
JavaScript
/// <reference types="vitest" />
|
|
import { defineConfig } from 'vite'
|
|
import react from '@vitejs/plugin-react'
|
|
import tailwindcss from '@tailwindcss/vite'
|
|
|
|
export default defineConfig({
|
|
plugins: [react(), tailwindcss()],
|
|
build: {
|
|
cssCodeSplit: true,
|
|
sourcemap: false,
|
|
chunkSizeWarningLimit: 450,
|
|
rollupOptions: {
|
|
output: {
|
|
manualChunks(id) {
|
|
if (!id.includes('node_modules')) return undefined;
|
|
if (id.includes('/react-router-dom/')) return 'router';
|
|
if (id.includes('/lenis/')) return 'motion';
|
|
if (id.includes('/react/') || id.includes('/react-dom/')) return 'react';
|
|
return 'vendor';
|
|
},
|
|
},
|
|
},
|
|
},
|
|
test: {
|
|
environment: 'jsdom',
|
|
globals: true,
|
|
setupFiles: ['./src/test/setup.js'],
|
|
include: ['src/**/*.test.{js,jsx}'],
|
|
coverage: {
|
|
reporter: ['text', 'lcov'],
|
|
include: ['src/lib/**', 'src/components/**'],
|
|
},
|
|
},
|
|
})
|