fix: 优化官网内容

This commit is contained in:
Daniel
2026-04-27 17:29:34 +08:00
parent 1d50532a8c
commit 6e394297b3
97 changed files with 1379 additions and 1720 deletions

33
quick-start.sh Executable file
View File

@@ -0,0 +1,33 @@
#!/usr/bin/env bash
set -euo pipefail
PROJECT_ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
cd "$PROJECT_ROOT"
echo "==> Official Network quick start"
if ! command -v node >/dev/null 2>&1; then
echo "Error: Node.js is not installed. Please install Node.js >= 16."
exit 1
fi
if ! command -v npm >/dev/null 2>&1; then
echo "Error: npm is not installed."
exit 1
fi
NODE_MAJOR="$(node -v | sed -E 's/^v([0-9]+).*/\1/')"
if [[ "${NODE_MAJOR}" -lt 16 ]]; then
echo "Warning: Detected Node.js $(node -v). Recommended: >= 16."
fi
if [[ ! -d node_modules ]]; then
echo "==> Installing dependencies..."
npm install
else
echo "==> node_modules exists, skipping install."
fi
echo "==> Starting development server..."
npm run serve