mirror of
https://github.com/lobehub/lobe-chat.git
synced 2026-06-13 19:20:04 +00:00
+8
-1
@@ -26,6 +26,9 @@ const nextConfig: NextConfig = {
|
||||
emotion: true,
|
||||
},
|
||||
compress: isProd,
|
||||
eslint: {
|
||||
ignoreDuringBuilds: true,
|
||||
},
|
||||
experimental: {
|
||||
optimizePackageImports: [
|
||||
'emoji-mart',
|
||||
@@ -195,6 +198,7 @@ const nextConfig: NextConfig = {
|
||||
},
|
||||
},
|
||||
reactStrictMode: true,
|
||||
|
||||
redirects: async () => [
|
||||
{
|
||||
destination: '/sitemap-index.xml',
|
||||
@@ -264,10 +268,13 @@ const nextConfig: NextConfig = {
|
||||
source: '/repos',
|
||||
},
|
||||
],
|
||||
|
||||
// when external packages in dev mode with turbopack, this config will lead to bundle error
|
||||
serverExternalPackages: isProd ? ['@electric-sql/pglite'] : undefined,
|
||||
|
||||
transpilePackages: ['pdfjs-dist', 'mermaid'],
|
||||
typescript: {
|
||||
ignoreBuildErrors: true,
|
||||
},
|
||||
|
||||
webpack(config) {
|
||||
config.experiments = {
|
||||
|
||||
+2
-2
@@ -29,14 +29,14 @@
|
||||
"packages/*"
|
||||
],
|
||||
"scripts": {
|
||||
"prebuild": "tsx scripts/prebuild.mts",
|
||||
"prebuild": "tsx scripts/prebuild.mts && npm run lint",
|
||||
"build": "cross-env NODE_OPTIONS=--max-old-space-size=6144 next build",
|
||||
"postbuild": "npm run build-sitemap && npm run build-migrate-db",
|
||||
"build-migrate-db": "bun run db:migrate",
|
||||
"build-sitemap": "tsx ./scripts/buildSitemapIndex/index.ts",
|
||||
"build:analyze": "NODE_OPTIONS=--max-old-space-size=6144 ANALYZE=true next build",
|
||||
"build:docker": "npm run prebuild && NODE_OPTIONS=--max-old-space-size=6144 DOCKER=true next build && npm run build-sitemap",
|
||||
"prebuild:electron": "cross-env NEXT_PUBLIC_IS_DESKTOP_APP=1 tsx scripts/prebuild.mts",
|
||||
"prebuild:electron": "cross-env NEXT_PUBLIC_IS_DESKTOP_APP=1 tsx scripts/prebuild.mts && npm run lint",
|
||||
"build:electron": "cross-env NODE_OPTIONS=--max-old-space-size=6144 NEXT_PUBLIC_IS_DESKTOP_APP=1 NEXT_PUBLIC_SERVICE_MODE=server next build",
|
||||
"clean:node_modules": "bash -lc 'set -e; echo \"Removing all node_modules...\"; rm -rf node_modules; pnpm -r exec rm -rf node_modules; rm -rf apps/desktop/node_modules; echo \"All node_modules removed.\"'",
|
||||
"db:generate": "drizzle-kit generate && npm run db:generate-client && npm run workflow:dbml",
|
||||
|
||||
Reference in New Issue
Block a user