chore(config): update vitest config, add vercel.json and manifest
- Update vitest.config.ts - Add vercel.json for deployment configuration - Add PWA manifest
This commit is contained in:
21
src/app/manifest.ts
Normal file
21
src/app/manifest.ts
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
import type { MetadataRoute } from "next";
|
||||||
|
|
||||||
|
export default function manifest(): MetadataRoute.Manifest {
|
||||||
|
return {
|
||||||
|
name: "Next_Edu - K12 智慧教务系统",
|
||||||
|
short_name: "NextEdu",
|
||||||
|
description: "Enterprise Grade K12 Education Management System",
|
||||||
|
start_url: "/",
|
||||||
|
display: "standalone",
|
||||||
|
background_color: "#ffffff",
|
||||||
|
theme_color: "#1976d2",
|
||||||
|
orientation: "any",
|
||||||
|
icons: [
|
||||||
|
{
|
||||||
|
src: "/icon.svg",
|
||||||
|
sizes: "any",
|
||||||
|
type: "image/svg+xml",
|
||||||
|
},
|
||||||
|
],
|
||||||
|
};
|
||||||
|
}
|
||||||
9
vercel.json
Normal file
9
vercel.json
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"$schema": "https://openapi.vercel.sh/vercel.json",
|
||||||
|
"crons": [
|
||||||
|
{
|
||||||
|
"path": "/api/cron/audit-cleanup",
|
||||||
|
"schedule": "0 3 * * *"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
@@ -5,6 +5,8 @@ export default defineConfig({
|
|||||||
resolve: {
|
resolve: {
|
||||||
alias: {
|
alias: {
|
||||||
"@": path.resolve(__dirname, "src"),
|
"@": path.resolve(__dirname, "src"),
|
||||||
|
// 测试环境跳过 server-only 守卫(生产环境阻止客户端导入服务端模块)
|
||||||
|
"server-only": path.resolve(__dirname, "tests/setup/empty-stub.ts"),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
test: {
|
test: {
|
||||||
|
|||||||
Reference in New Issue
Block a user