RLS policies implementeren, Demo auth flow
This commit is contained in:
@@ -1,7 +1,53 @@
|
||||
import type { NextConfig } from "next";
|
||||
|
||||
const nextConfig: NextConfig = {
|
||||
/* config options here */
|
||||
// Performance optimizations
|
||||
compress: true, // Enable gzip compression
|
||||
|
||||
// Optimize images (if any are added later)
|
||||
images: {
|
||||
formats: ['image/avif', 'image/webp'],
|
||||
deviceSizes: [640, 750, 828, 1080, 1200, 1920, 2048, 3840],
|
||||
imageSizes: [16, 32, 48, 64, 96, 128, 256, 384],
|
||||
},
|
||||
|
||||
// Experimental features for better performance
|
||||
experimental: {
|
||||
optimizePackageImports: ['lucide-react', '@react-three/fiber', '@react-three/drei'],
|
||||
},
|
||||
|
||||
// Webpack optimizations
|
||||
webpack: (config, { isServer }) => {
|
||||
// Optimize bundle size
|
||||
if (!isServer) {
|
||||
config.optimization = {
|
||||
...config.optimization,
|
||||
moduleIds: 'deterministic',
|
||||
splitChunks: {
|
||||
chunks: 'all',
|
||||
cacheGroups: {
|
||||
default: false,
|
||||
vendors: false,
|
||||
// Vendor chunk for heavy libraries
|
||||
vendor: {
|
||||
name: 'vendor',
|
||||
chunks: 'all',
|
||||
test: /node_modules/,
|
||||
priority: 20,
|
||||
},
|
||||
// Separate chunk for three.js (heavy)
|
||||
three: {
|
||||
name: 'three',
|
||||
chunks: 'all',
|
||||
test: /[\\/]node_modules[\\/](three|@react-three)[\\/]/,
|
||||
priority: 30,
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
||||
}
|
||||
return config;
|
||||
},
|
||||
};
|
||||
|
||||
export default nextConfig;
|
||||
|
||||
Reference in New Issue
Block a user