Skip to main content

Generate Code from TODOs

What it does?

The Generate Code from TODOs command automatically creates code based on TODO comments in your codebase. These TODOs are often placeholders for future development or functionality. This command helps you quickly implement these planned features or logic directly from your notes.

Why to use it?

tip

This command supports all programming languages and frameworks.

To speed up development by turning TODO comments into actual, functional code. This command is particularly useful for developers who jot down ideas or outline functionality with TODOs and want to convert them into working code without the hassle of starting from scratch.

When to use it?

  • You’ve marked sections of your code with TODO comments that outline needed functionality or improvements.
  • You’re moving from a planning phase to a development phase and want to implement the functionality directly from your outlined TODOs.
  • You want to ensure that all planned features and logic are implemented correctly and consistently.
  • You’re reviewing the codebase and notice unfinished TODOs that need to be addressed with actual code.

How to use it?

1

Select code

Select the entire file’s code which contains the TODO comment.

2

Select command

Right-click to open the context menu, select WiseGPT, and then select Generate Code from TODOs.

tip

You can also click on the light bulb (💡) icon next to the selected code, then select Generate Code from TODOs.

3

Review code

WiseGPT will generate the appropriate code based on the TODO description. Review the generated code and integrate it into your codebase.

Generate Code from TODOs

Before:

Before

After:

After