Files
pay-bridge/CLAUDE.md
2026-02-12 11:10:38 +08:00

52 lines
935 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# CLAUDE.md
本文件为 Claude Code (claude.ai/code) 在此仓库中工作时提供指导。
## 项目概述
**pay-bridge** 是一个前后端一体的全栈应用,前端使用 React后端使用 Go。目前处于早期/模板阶段。
- **前端**: React
- **后端**: Go (Go 1.25)
## 构建与运行命令
### 后端
```bash
# 运行
go run main.go
# 构建
go build -o pay-bridge .
# 测试
go test ./...
# 运行单个测试
go test -run TestName ./path/to/package
# 代码检查
go vet ./...
```
### 前端
```bash
# 安装依赖
cd frontend && npm install
# 开发服务器
cd frontend && npm run dev
# 构建
cd frontend && npm run build
```
## 架构
前后端一体的 monorepo 项目。
- **后端**: Go 模块 (`module pay-bridge`),提供 API 服务并托管前端静态资源。遵循 Go 标准目录结构 (`cmd/`, `internal/`, `pkg/`)。
- **前端**: React 应用,位于 `frontend/` 目录。