{"meta":{"title":"Document code","intro":"Discover ways that you can use GitHub Copilot Chat to document your code.","product":"GitHub Copilot","breadcrumbs":[{"href":"/en/copilot","title":"GitHub Copilot"},{"href":"/en/copilot/tutorials","title":"Tutorials"},{"href":"/en/copilot/tutorials/copilot-cookbook","title":"GitHub Copilot Cookbook"},{"href":"/en/copilot/tutorials/copilot-cookbook/document-code","title":"Document code"}],"documentType":"subcategory"},"body":"# Document code\n\nDiscover ways that you can use GitHub Copilot Chat to document your code.\n\n## Links\n\n* [Filing issues without breaking your flow](/en/copilot/tutorials/copilot-cookbook/document-code/filing-issues-without-breaking-your-flow)\n\n  When something catches your attention mid-task, use Copilot CLI to file a GitHub issue with code context, linked PRs, and labels, then get back to what you were doing.\n\n* [Documenting legacy code](/en/copilot/tutorials/copilot-cookbook/document-code/document-legacy-code)\n\n  Copilot Chat can help with documenting legacy code.\n\n* [Explaining legacy code](/en/copilot/tutorials/copilot-cookbook/document-code/explain-legacy-code)\n\n  Copilot Chat can help with explaining unfamiliar code.\n\n* [Explaining complex algorithms or logic](/en/copilot/tutorials/copilot-cookbook/document-code/explain-complex-logic)\n\n  Copilot Chat can help add clear and concise documentation on complex algorithms or logic.\n\n* [Syncing documentation with code changes](/en/copilot/tutorials/copilot-cookbook/document-code/sync-documentation)\n\n  Copilot Chat can help with keeping code documentation up-to-date.\n\n* [Writing discussions or blog posts](/en/copilot/tutorials/copilot-cookbook/document-code/write-discussions-or-blog-posts)\n\n  Copilot Chat can help you generate ideas, outline, or draft discussions or blog posts."}