"Code Refactor" Github Issues Template

"Code Refactor" Github Issues Issue Template

Use our "Code Refactor" Github Issues issue template to help your teams build better, faster.
Code Refactor Image
Magical.pm

Finding the Right Template For Your Team

Selecting the right Github Issues issue template is important in building your product and project management workflow. Some teams prefer simple, sparse issues that get to the point, while others prefer complex, documentation-rich issues. Each team is different, and your template should evolve as your team's needs change. With that in mind, we've assembled a library of Github Issues issue templates to help your team find what works. Our "Code Refactor" template, which you can find below, is a great starting point.

What Does "Right" Look Like?

The right Github Issues issue template will match your team's stage, maturity, and purpose. Early in the product development process, your team is likely small and working on proof of concepts, where flexibility and quick pivots are key to success. Your team will likely want the lightest-weight issue template possible at this stage, enabling quick iteration without the burden of unnecessary documentation. Your issue template will evolve with your team, and as your team grows, so will your processes. Even with team growth, it's important to document as little as possible to maintain agility. The phrase "as little as possible" is intentionally chosen. If you under-document, you will lack a history of your team's work, the decisions you made, and their "why." You don't want to over-document, either. A good barometer for this is to ask yourself, "Is someone going to read what I'm writing?" If the answer is "yes," you're probably on the right track. If the answer is "no" or "not really," you're probably over-documenting. Striking the right balance is key to maintaining your velocity, and selecting the right Github Issues issue template can help you stay on the right track.
1
Stage-Appropriate
Ensure your template strikes the right balance between over- and under-documenting.
2
Flexible
Maintain flexibility as your team grows by optimizing for the least documentation possible.
Template

Our "Code Refactor" Template

You can copy and paste this Github Issues issue template into Github Issues to create your own, or use Magical.pm to generate it with AI.

Code Refactor Task

Explain why refactoring is needed.

Current Code Issues

List technical debt concerns.

Refactoring Plan

Describe the steps to refactor.

To-do List

  • Task 1
  • Task 2

Acceptance Criteria

  1. Criterion 1
  2. Criterion 2
  3. Criterion 3.
Good PMs use templates. Great PMs use templates in Magical.pm.Generate "Code Refactor" issues with Magical.pm, the AI product management co-pilot.
Example

"Code Refactor" Template Example

Here's an example of our Github Issues issue template in action.

Code Refactor Task

Refactor the R2-D2 Navigation Subroutines to improve efficiency and maintainability. Current code is a tangled mess of patched logic accumulated over decades, making debugging as difficult as understanding droid beeps without C-3PO.

Current Code Issues

Spaghetti Code: Legacy logic from the Clone Wars era mixed with Rebel Alliance patches.
Redundant Calculations: Multiple overlapping star map lookups slow down route optimization.
Hardcoded Paths: Direct coordinates to Tatooine, Hoth, and Endor hardcoded instead of using dynamic route generation.

Refactoring Plan

• Modularize navigation functions into separate, reusable components.
• Optimize hyperspace jump calculations to reduce redundant processing.
• Replace hardcoded routes with a dynamic galactic mapping system.
• Upgrade outdated dependencies (no more relying on 1977-era tech).

To-Do:

• Identify and isolate redundant navigation logic.
• Implement modular functions for route calculation and obstacle avoidance.
• Write unit tests to validate optimized hyperspace jump paths.
• Deploy updates and monitor R2’s performance on live missions.

Acceptance Criteria:

• Navigation subroutines execute 30% faster than before.
• Code is modular and well-documented, allowing easy maintenance.
• No unintended detours into Sith-controlled territory.
• R2-D2 stops making distressed beeping noises when processing hyperspace routes.

Generating Github Issues Issues with Magical.pm

While you can use this template manually in Github Issues, it's also compatible with Magical.pm, our AI issue generator. Using Magical.pm, you can instantly turn natural language like "unsink the Titanic" (feeling brave?) into perfectly formatted Github Issues issues. Magical.pm works hand-in-hand with Github Issues. When you generate a issue with Magical.pm, it is formatted in markdown, meaning it will perfectly copy into Github Issues, retaining everything from code blocks to headings. Internally, we copy issues from Magical.pm to Github Issues daily, making our workflows significantly faster. This workflow strikes a healthy balance: everything we love about human-generated requirements – the details and context – without the cognitive load and time overhead of perfect formatting, grammar, and writing.
Generate a issue with Magical.pm in seconds
1
Write lazy requirements"when the user types in the field, turn the button #5260FF"
2
Get perfectly formatted requirementsMagical.pm will return perfectly formatted requirements.
3
Copy and paste into your toolsBe it Linear, Jira, Confluence – or anything else. Magical.pm's requirements are in markdown format.
4
Go further with TemplatesSelect the perfect template for your use case.
Lazy RequirementsDescribe your product requirements in natural language.
Your CardReady for dev, in seconds.
A funny thing happens when writing a PRD takes seconds...You start shipping. A lot.
Code Refactor Image
Magical.pm

Use Magical.pm to Generate Perfect Github Issues Issues Every Time

Generate Github Issues Issues with Magical.pm