Skip to content

Commit 499f66d

Browse files
committed
feat: fix vercel build
1 parent 767ed95 commit 499f66d

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

.vercel/build.sh

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
#!/bin/bash
2+
3+
# Exit on error
4+
set -e
5+
6+
echo "Starting custom Vercel build script"
7+
8+
# Remove existing package-lock.json and node_modules to avoid npm optional dependency bug
9+
echo "Cleaning up existing installations"
10+
rm -rf package-lock.json node_modules
11+
rm -rf apps/client/node_modules
12+
13+
# Install dependencies with specific flags to handle Rollup's optional dependencies
14+
echo "Installing dependencies"
15+
npm install --no-optional --force
16+
17+
# Build the client application
18+
echo "Building client application"
19+
cd apps/client
20+
npm run build
21+
22+
echo "Build completed successfully"

0 commit comments

Comments
 (0)