27 lines
772 B
TypeScript
Executable file
27 lines
772 B
TypeScript
Executable file
import { defineConfig } from 'vite';
|
|
import path from 'path';
|
|
|
|
export default defineConfig({
|
|
root: __dirname,
|
|
define: {
|
|
// Polyfill process.env for libraries that expect Node.js environment
|
|
'process.env': {},
|
|
'process.env.NODE_ENV': JSON.stringify('development'),
|
|
// Enable mock data for E2E tests
|
|
'process.env.MOCK_ANALYTICS': JSON.stringify('true'),
|
|
},
|
|
resolve: {
|
|
alias: {
|
|
'@ui/primitives': path.resolve(__dirname, '../../src/components/ui-stubs'),
|
|
'@ui/data': path.resolve(__dirname, '../../src/components/ui-data-stubs'),
|
|
'@ui/utils': path.resolve(__dirname, '../../src/components/ui-utils-stubs'),
|
|
},
|
|
},
|
|
esbuild: {
|
|
jsx: 'automatic',
|
|
jsxImportSource: 'react',
|
|
},
|
|
server: {
|
|
port: 3000,
|
|
},
|
|
});
|