Chuyển đến nội dung
Skillpedia
Website và giao diện (frontend)75k · #2773

clean-up-comments

Skill này làm gì

Skill này kiểm tra HTML của bản đưa lên mạng để tìm ghi chú, code gỡ lỗi và đánh dấu không dùng đến mà không nên công khai. Skill dành cho lập trình viên muốn trang sạch và an toàn trước khi ra mắt.

Khi nào nên dùng

  • ✓Khi bạn chuẩn bị đưa một website hoặc trang lên mạng.
  • ✓Khi mã nguồn trang hiển thị ghi chú TODO hoặc gỡ lỗi chỉ dành cho lập trình viên.
  • ✓Khi build xuất ra comment hoặc code console cần phải gỡ bỏ.

Liên kết skill

https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/clean-up-comments/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/thedaviddias/Front-End-Checklist/blob/main/skills/clean-up-comments/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Hãy dọn dẹp HTML trang đích của tôi để ghi chú lập trình viên và đánh dấu gỡ lỗi được xóa trước khi ra mắt.”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Agent rà soát template và HTML đã render để tìm TODO, FIXME, ghi chú gỡ lỗi, đánh dấu còn sót và chi tiết nhạy cảm, rồi xóa chúng nhưng giữ lại các ghi chú về khả năng truy cập và pháp lý.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

Remove comments and debug code in production

Comments expose internal logic to attackers, increase file size, and can leak sensitive information like API endpoints, credentials, or system architecture.

Quick Reference

  • Remove TODO, FIXME, DEBUG comments before production
  • Keep accessibility and legal comments
  • Configure build tools to strip comments automatically
  • Review for sensitive data leaks in comments

Check

Review this HTML code for unnecessary comments, debug code, console logs, and temporary markup that should be removed before production deployment.

Fix

Remove all development comments, debug code, unused markup, and temporary elements from the HTML before deploying to production.

Explain

Explain why cleaning up code before production is important for security, performance, and professional presentation of web applications.

Code Review

Review templates, server-rendered HTML, and shared components that output markup related to Remove comments and debug code in production. Flag exact elements, attributes, and routes where the rendered HTML violates the rule.


For full implementation details, code examples, and framework-specific guidance, see references/rule.md.

Rule page: https://frontendchecklist.io/rules/html/clean-up-comments

Câu hỏi thường gặp

Vì sao comment có thể là rủi ro bảo mật?

Skill nói chúng có thể để lộ logic nội bộ, địa chỉ API hoặc chi tiết hệ thống cho bất kỳ ai xem mã nguồn trang.

Những comment nào nên giữ lại?

Theo skill, đó là các comment về khả năng truy cập và pháp lý.

Công cụ build có thể tự xóa comment không?

Có. Skill gợi ý cấu hình công cụ build để loại bỏ comment.

Chi tiết

Mô tả gốc của tác giả

Use when reviewing templates, rendered HTML, or shared components related to Remove comments and debug code in production. Validate the final browser-facing markup, not just the source framework abstraction.

repo: thedaviddias/Front-End-Checklist

Độ phổ biến

Sao GitHub
75k
Vị trí xếp hạng
#2773
Giấy phép
MIT
Cập nhật
31/10/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự