No Description

FanLide 5833a3184b feat: 完善了国际化功能 和页面 2 weeks ago
doc 5833a3184b feat: 完善了国际化功能 和页面 2 weeks ago
src 5833a3184b feat: 完善了国际化功能 和页面 2 weeks ago
.env.development 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
.env.local.backup 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
.env.local.example 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
.env.production 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
.gitignore 5833a3184b feat: 完善了国际化功能 和页面 2 weeks ago
README.md 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
components.d.ts 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
env.d.ts 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
index.html 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
jsconfig.json 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
package-lock.json 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
package.json 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
tsconfig.app.json 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
tsconfig.json 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
tsconfig.node.json 5b0c9db2e2 chore: initial commit as independent project 2 weeks ago
vite.config.ts d4f792fa2b feat: align API endpoints with Swagger and enhance TypeScript definitions 2 weeks ago

README.md

LINE Order App

LINE订餐系统 - 基于Vue 3 + LIFF的移动端Web应用

技术栈

  • 框架: Vue 3 (Composition API)
  • 构建工具: Vite 5
  • 状态管理: Pinia 2
  • 路由: Vue Router 4
  • UI组件: Vant 4
  • HTTP请求: Axios
  • WebSocket: Socket.IO Client
  • 国际化: vue-i18n 9
  • LINE SDK: @line/liff
  • 工具库: dayjs, @vueuse/core

项目结构

line-order-app/
├── public/              # 静态资源
├── src/
│   ├── api/            # API接口
│   ├── assets/         # 资源文件
│   ├── components/     # 组件
│   ├── composables/    # 组合式函数
│   ├── config/         # 配置
│   ├── locale/         # 国际化
│   ├── router/         # 路由
│   ├── store/          # 状态管理
│   ├── utils/          # 工具函数
│   ├── views/          # 页面
│   ├── App.vue         # 根组件
│   └── main.js         # 入口文件
├── .env.development    # 开发环境变量
├── .env.production     # 生产环境变量
├── vite.config.js      # Vite配置
├── package.json
└── README.md

开发指南

环境要求

  • Node.js >= 18.0.0
  • npm >= 9.0.0

安装依赖

npm install

开发模式

npm run dev

构建生产

npm run build

预览构建结果

npm run preview

环境配置

开发环境 (.env.development)

  • VITE_API_URL: API地址
  • VITE_WS_URL: WebSocket地址
  • VITE_LIFF_ID: LINE LIFF ID
  • VITE_TENANT_ID: 租户ID

生产环境 (.env.production)

同上

LIFF配置

  1. LINE Developers Console 创建LIFF应用
  2. 获取LIFF ID
  3. 配置到环境变量 VITE_LIFF_ID

重构进度

详见 REFACTOR_PLAN.md

License

MIT