Shortcuts, tips, and best practices
Copilot reads your comments. The more specific, the better the code it generates.
Good function names give Copilot context about what you want.
Show Copilot what you expect with input/output examples.
Write the first item in a series, Copilot will continue the pattern.
Copilot uses open tabs for context. Keep relevant files open.
Copilot can generate code that looks right but has bugs, security issues, or uses outdated patterns. Never blindly accept suggestions—especially for authentication, database queries, or anything handling user input.
Copilot doesn't know your specific requirements. Break complex logic into smaller, well-named functions.
Copilot's training data has a cutoff. It may suggest outdated patterns for newer tools. Check docs.
It can't know your internal APIs. Provide type hints or examples in comments.