-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnext.config.ts
More file actions
33 lines (31 loc) · 1.01 KB
/
Copy pathnext.config.ts
File metadata and controls
33 lines (31 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
import type { NextConfig } from "next";
import path from "path";
const nextConfig: NextConfig = {
outputFileTracingRoot: path.join(__dirname),
// Keep the y-stack out of the Next.js bundle so the server uses Node's
// resolution and loads each package exactly once. Bundling them caused the
// "Yjs was already imported" warning — Next was loading the ESM build while
// a transitive (e.g. y-protocols) loaded the CJS build.
serverExternalPackages: [
"yjs",
"y-protocols",
"y-monaco",
"y-websocket",
"@hocuspocus/provider",
"@hocuspocus/server",
],
// /api/deploy-to-vercel reads these at runtime as the shadcn snapshot for
// sessions whose sandbox has died. Force them into the serverless bundle.
outputFileTracingIncludes: {
"/api/deploy-to-vercel": [
"src/components/ui/**",
"src/lib/utils.ts",
],
},
allowedDevOrigins: [
"http://192.168.1.103:3000",
"http://192.168.1.108:3000",
"http://192.168.*.*:3000",
],
};
export default nextConfig;