Wrap the service worker registration logic in a try-catch block to prevent uncaught exceptions when Service Workers are not supported or fail to load. Log a debug message on failure and return null instead of propagating the error. This improves application robustness in environments without Service Worker support. |
||
|---|---|---|
| __test__ | ||
| .vscode | ||
| assets | ||
| prisma | ||
| src | ||
| .env.example | ||
| .gitignore | ||
| bun-env.d.ts | ||
| bun.lock | ||
| bunfig.toml | ||
| docker-compose.yml | ||
| dockerfile | ||
| package.json | ||
| prisma.config.ts | ||
| README.md | ||
| tsconfig.json | ||
My-Kaiqiuwang
To install dependencies:
bun install
To start a development server:
bun dev
To run for production:
bun start
This project was created using bun init in bun v1.2.21. Bun is a fast all-in-one JavaScript runtime.
Database
Prisma
设计阶段
bun --env-file=.env.development prisma db push
开发阶段, 生成代码
bun --env-file=.env.development prisma generate
在开发环境生成 migration 文件
bun --env-file=.env.development prisma migrate dev --name=<name>
同步到测试环境,跑测试用例用(如果需要的话)
bun --env-file=.env.test prisma migrate deploy