Files
NextEdu/src/modules/course-plans/lib/track-event.ts
SpecialX 98429e87eb feat(business): update audit, auth, course-plans, announcements, exams
- audit: update retention.ts, types.ts, audit-retention-settings.tsx

- auth: update actions.ts and types.ts

- course-plans: update actions.ts, course-plan-detail.tsx, template-picker-dialog.tsx,

  add lib/track-event.ts

- announcements: update page.tsx, announcement-list.tsx, announcement-pagination.tsx

- exams: update actions.ts
2026-07-04 10:23:03 +08:00

20 lines
653 B
TypeScript
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.
/**
* 课程计划监控埋点接口P2-8
*
* 供客户端组件直接调用以记录关键操作。
* 当前为空实现,后续接入监控 SDK 时只需修改此函数。
*
* 注意:此文件不得标记 "use server",因为 trackCoursePlanEvent 是同步函数,
* 不涉及服务端操作。Next.js 16 要求 "use server" 文件中所有导出必须是 async 函数。
*/
export function trackCoursePlanEvent(
event: string,
properties?: Record<string, unknown>,
): void {
// 预留:接入监控 SDK 后实现
if (process.env.NODE_ENV === "development") {
console.debug(`[course-plans] ${event}`, properties)
}
}