ai-ops-cli 0.2.2 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
## Backend TS Library Constraints
|
|
20
20
|
|
|
21
21
|
- Do not use moment/dayjs.
|
|
22
|
+
- Do not parse date strings with `new Date(string)`. It applies implicit local timezone coercion and silently shifts dates.
|
|
22
23
|
- Do not use jsonwebtoken.
|
|
23
24
|
- Do not handle Express req/res directly in NestJS handlers.
|
|
24
25
|
- Do not import lodash as a full bundle.
|
|
@@ -29,6 +30,7 @@
|
|
|
29
30
|
|
|
30
31
|
- Use class-validator and class-transformer DTO validation.
|
|
31
32
|
- Use jose for JWT sign/verify and JWKS workflows.
|
|
33
|
+
- Use date-fns for date manipulation; import functions individually (e.g. `import { parseISO, format } from 'date-fns'`).
|
|
32
34
|
- Use pino via nestjs-pino for structured logs.
|
|
33
35
|
- Use rxjs operators in interceptors, guards, and event streams.
|
|
34
36
|
- Use Vitest with @nestjs/testing and supertest.
|
|
@@ -40,4 +42,5 @@
|
|
|
40
42
|
- When auth or roles depend on handler metadata, use guards.
|
|
41
43
|
- When response transformation or timing is needed, use interceptors.
|
|
42
44
|
- When JWT auth is needed, use jose.
|
|
45
|
+
- When parsing an ISO date string, use `parseISO()` from date-fns; avoid `new Date(string)`.
|
|
43
46
|
- When structured logging is needed, use pino via nestjs-pino.
|
package/data/skills/reference-skills/frontend-web-react-next-runtime/references/reference.md
CHANGED
|
@@ -27,6 +27,7 @@
|
|
|
27
27
|
## Web Frontend Library Constraints
|
|
28
28
|
|
|
29
29
|
- Do not use moment.js or dayjs.
|
|
30
|
+
- Do not parse date strings with `new Date(string)`. It applies implicit local timezone coercion and silently shifts dates.
|
|
30
31
|
- Do not use react-icons.
|
|
31
32
|
- Do not use axios in browser code.
|
|
32
33
|
- Do not build conditional className strings manually.
|
|
@@ -36,6 +37,7 @@
|
|
|
36
37
|
## Web Frontend Library Guidelines
|
|
37
38
|
|
|
38
39
|
- Keep styling on Tailwind and design tokens.
|
|
40
|
+
- Use date-fns for date formatting and manipulation; import functions individually (e.g. `import { parseISO, format } from 'date-fns'`).
|
|
39
41
|
- Use next-intl for i18n and next-themes for theme switching.
|
|
40
42
|
- Render Recharts only inside client components.
|
|
41
43
|
- Mount one Sonner toaster at the app root.
|
|
@@ -48,4 +50,5 @@
|
|
|
48
50
|
- When page data is needed for first render, fetch in server components.
|
|
49
51
|
- When internal form mutation is needed, use server actions.
|
|
50
52
|
- When form validation is needed, use zod with react-hook-form.
|
|
53
|
+
- When parsing an ISO date string, use `parseISO()` from date-fns; avoid `new Date(string)`.
|
|
51
54
|
- When client UI state is needed, use a zustand slice.
|