cgw-best-practices
Use before writing or changing TypeScript in safe-client-gateway PRODUCTION code (src/, excluding spec files) - the cross-cutting dos and don'ts that no domain guide owns and biome does not fully catch. Covers parse-don't-assert (no `as X` or `as unknown as X` on data whose shape the compiler cannot guarantee), no `any` and no @ts-ignore/@ts-expect-error, no non-null assertions, `import type` for type-only imports (with the Symbol-DI-token exception), ILoggingService instead of console.*, no silently swallowed errors in a catch block, `private readonly` injected dependencies, explicit return types on exported methods, and named constants over inline magic values. Triggers on any production TypeScript edit, plus "type error", "cast", "as unknown", "as any", "catch block", "console.log", "magic number". For casts inside a spec file load cgw-testing and cgw-remarks instead - the test-mock cast idiom is the one sanctioned exception and those two own it.
معلومات المصدر
- المستودع
- safe-global/safe-client-gateway
- آخر نشاط في المصدر
- ٧ أغسطس ٢٠٢٦ في ١٢:٤٦
- لغة SKILL.md المكتشفة
- الإنجليزية
- النجوم
- ٥٠
- التفرعات
- ١٠٢
خيارات التثبيت
يُحدَّد Prompt الذي يراجع المصدر أولًا بشكل افتراضي. يمكنك التبديل إلى أمر مباشر أو تنزيل نسخة محلية.
مراجعة ملفات المصدر
اقرأ SKILL.md وأي ملفات مرافقة يعرضها SkillsMP قبل أن تقرر التثبيت.