.agent/skills/typescript-error-explainer/SKILL.md
Giải thích lỗi TypeScript một cách dễ hiểu bằng tiếng Việt. Sử dụng khi gặp lỗi type, generic, inference, hoặc bất kỳ lỗi TS nào cần được giải thích rõ ràng.
npx skillsauth add vuthuonghai-steve/KLTN-By_Thuong_Hai-Steve typescript-error-explainerInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Skill này giúp giải thích các lỗi TypeScript bằng tiếng Việt, dễ hiểu cho cả người mới học.
| Mã lỗi | Loại | Ý nghĩa | |--------|------|---------| | TS2322 | Type Mismatch | Không thể gán type A cho type B | | TS2339 | Property Missing | Property không tồn tại trên type | | TS2345 | Argument Type | Argument không khớp với parameter | | TS2531 | Possibly Null | Object có thể là null/undefined | | TS2551 | Typo Suggestion | Có thể bạn muốn viết... | | TS2304 | Cannot Find Name | Không tìm thấy tên/biến/type | | TS2307 | Module Not Found | Không tìm thấy module | | TS2769 | Overload Mismatch | Không khớp với bất kỳ overload nào | | TS7006 | Implicit Any | Parameter ngầm định là 'any' |
## 🔴 [Mã lỗi] - [Tên lỗi ngắn gọn]
### Thông báo lỗi
> [Copy nguyên văn]
### Giải thích đơn giản
[1-2 câu bằng ngôn ngữ đời thường]
### Nguyên nhân
[Phân tích ngắn gọn tại sao xảy ra]
### Cách sửa
\`\`\`typescript
// Code sửa lỗi
\`\`\`
### Lưu ý
[Tips phòng tránh lỗi tương tự]
Ví dụ: Type 'string' is not assignable to type 'number'
Giải thích: Bạn đang gán chuỗi vào biến kiểu số. Giống như nhét quả táo vào hộp chỉ dành cho cam.
Cách sửa:
parseInt(), toString())Ví dụ: Property 'name' does not exist on type 'User'
Giải thích: Type User chưa khai báo property name.
Cách sửa:
user?.nameVí dụ: Object is possibly 'null'
Giải thích: Biến có thể null, truy cập trực tiếp sẽ crash.
Cách sửa:
// Optional chaining
user?.name
// Nullish coalescing
user?.name ?? 'Default'
// Type guard
if (user) { user.name }
// Non-null assertion (chỉ khi CHẮC CHẮN)
user!.name
Ví dụ: Argument of type 'string' is not assignable to parameter of type 'number'
Giải thích: Function yêu cầu số nhưng bạn truyền chuỗi.
Cách sửa:
Ví dụ: Parameter 'x' implicitly has an 'any' type
Giải thích: Strict mode yêu cầu khai báo type rõ ràng.
Cách sửa:
// ❌ Lỗi
function process(data) { }
// ✅ Đúng
function process(data: MyType) { }
is not assignable to: Không thể gándoes not exist on: Không tồn tạipossibly: Có thể null/undefinedimplicitly: Thiếu khai báoany - Trừ khi cực kỳ cần thiết@ts-ignore - Mà không giải thích lý dotools
Automates end-to-end drawing of UI screens in Pencil canvas from module spec files. Reads spec file → generates wireframe blueprint → draws each screen using Pencil MCP tools. Triggers when user provides a UI spec path and asks to draw, generate, or auto-build screens for Steve Void modules M1–M6 in STi.pen.
testing
Extracts UI Screen Specs by analyzing Schema and Diagrams. Use when you need to bridge database logic and flow diagrams into intermediate UI component specifications for a given module. Trigger when user says "analyze UI for module X", "generate ui spec", "phân tích UI module", or invokes "ui-architecture-analyst --module M[X]".
development
Giải thích lỗi TypeScript một cách dễ hiểu bằng tiếng Việt. Sử dụng khi gặp lỗi type, generic, inference, hoặc bất kỳ lỗi TS nào cần được giải thích rõ ràng.
development
Skill phan tach yeu cau/tinh nang thanh cac phase, task va subtask cu the. Tao bo tai lieu planning clean, khong chua code mau, tap trung mo ta logic va nghiep vu. Su dung khi: (1) nhan yeu cau tinh nang moi can lap ke hoach, (2) co tai lieu nghien cuu can chuyen thanh task plan, (3) nguoi dung yeu cau phan tach cong viec, (4) can tao roadmap trien khai cho du an/tinh nang. Trigger: /task-planner, /plan-tasks, "phan tach task", "lap ke hoach", "tao plan", "chia phase".