Refactoring

Refactoring

Keep your code solid, dry, and easy to maintain.

Refactoring is a process of improving your source code without creating a new functionality. It helps you keep your code solid, dry, and easy to maintain.

See Also

File-scoped namespaces and types

Tip

File-scoped namespaces and types
Organize code better and reduce bugs by using file-scoped namespaces and objects
C# Top-level statements

Tip

C# Top-level statements
Use top-level statements in C# to reduce boilerplate code.
Global usings

Tip

Global usings
Organize `using` statements so they're out of your way.
Refactoring

Part of tutorial

Refactoring
Refactoring code for understanding
Refactor rename with AI Assistant

Tip

Refactor rename with AI Assistant
Use the power of AI Assistant for even better naming suggestions
Extract Method

Tip

Extract Method
Extract code to a new method
Inline Variable

Tip

Inline Variable
Inline a variable in your code
Introduce variable

Tip

Introduce variable
Refactor your code and introduce a new variable
Generate Code

Tip

Generate Code
Helps you to generate commonly used code constructs
Highlights of GoLand 2023.3

Playlist

Highlights of GoLand 2023.3
Explore key features and enhancements in GoLand 2023.3.
Create a function in another package

Tip

Create a function in another package
Type a non-existing function name and generate its implementation in a package of your choice
Empower your `Printf`-like functions with coding assistance

Tip

Empower your `Printf`-like functions with coding assistance
Provide hints and highlights for message formats in custom `Printf`-like functions
Introduce parameters from unresolved references in your code

Tip

Introduce parameters from unresolved references in your code
Change a function or method signature by introducing parameters directly from unresolved references
Use collection initializers

Tip

Use collection initializers
Update and initialize items in old collection declarations
Rename refactoring

Tip

Rename refactoring
Would a variable by any other name read as clearly?
Extract method refactoring

Tip

Extract method refactoring
Split and Organize code into DRY, discrete units.
Inline method refactoring

Tip

Inline method refactoring
Replace usages of a function with its implementation.
Replace Assets

Part of tutorial

Replace Assets
Replace assets on your scene. It's like refactoring, but visually!
C# 11 - Required Keyword

Tip

C# 11 - Required Keyword
Introducing the required keyword for fields and properties.
Refactor Rename

Tip

Refactor Rename
Renaming classes, methods, and variables in IntelliJ IDEA
C# 11 - Raw strings

Tip

C# 11 - Raw strings
There is no escape!
Extract Variable

Tip

Extract Variable
Extract code to a variable
Refactor this

Tip

Refactor this
Refactoring options for the selection
Merge/Unmerge If Statements

Tip

Merge/Unmerge If Statements
Experiment with your code without changing the semantics
Inject a language

Tip

Inject a language
Language injections let you work with pieces of code in other languages embedded in your code.
Pattern Matching for Switch

Tip

Pattern Matching for Switch
Available in preview from Java 17
Migrating from the `javax` to `jakarta` namespace

Tutorial

Migrating from the `javax` to `jakarta` namespace
How to transition your application from Java EE to Jakarta EE.
Manage VCS Changelists in IntelliJ IDEA

Tip

Manage VCS Changelists in IntelliJ IDEA
Group and commit changes related to certain tasks
Write SQL queries using popular database packages

Tip

Write SQL queries using popular database packages
Work with SQL queries and get completion and other features automatically.
Refactor names in React useState hooks

Tip

Refactor names in React useState hooks
Rename both values of from useState hooks at once
Extract Type Refactoring

Tip

Extract Type Refactoring
Extract a type into its own definition and improve the reusability in your code
Rename Go module refactoring

Tip

Rename Go module refactoring
Upgrade Go modules to newer versions with ease
Legacy Refactoring

YouTube

Legacy Refactoring
Lorraine Steyn
Refactoring Code with ReSharper

Part of tutorial

Refactoring Code with ReSharper
How to safely refactor code, without breaking the build? Let's have a look.
Add Overload Bool

Tip

Add Overload Bool
You can refactor a method to change its signature
Assert That Import

Tip

Assert That Import
Use quick intentions to manage imports
Change Method Signature

Tip

Change Method Signature
Refactor the signature of a method
Convert Concatenation To Template

Tip

Convert Concatenation To Template
Use quick intentions to convert to a template string
Remove Unnecessary Condition

Tip

Remove Unnecessary Condition
Use quick intentions to remove redundant code
Convert to Expression Body

Tip

Convert to Expression Body
Use quick intentions to convert to use expression body syntax
Extract Constant

Tip

Extract Constant
Extract a value to a constant
Extract Field

Tip

Extract Field
Extract code to a field
Extract Parameter

Tip

Extract Parameter
Extract code to a parameter in Kotlin
Extract Parameter

Tip

Extract Parameter
Extract code to a parameter
Extract Variable

Tip

Extract Variable
Extract code to a variable
Inline a method

Tip

Inline a method
Inline a method
Meaningless Arguments

Tip

Meaningless Arguments
Use quick intentions to remove redundant code
Rename an Interface

Tip

Rename an Interface
Renaming in IntelliJ IDEA including comments and texts
Replace with var

Tip

Replace with var
Use quick intentions to replace a local variable type with `var`
Refactor an Unreachable Statement

Tip

Refactor an Unreachable Statement
Use quick intentions to remove redundant code
Refactoring

Part of tutorial

Refactoring
See how the IDE helps you safely refactor code, without breaking existing code.
Rename a File and Its References

Tip

Rename a File and Its References
Change your mind on a file name, and the IDE makes all the changes for you.
Rename Symbol

Tip

Rename Symbol
Change a variable name, class name, or other symbol, across the project.
Refactoring code in Rider

Part of tutorial

Refactoring code in Rider
Learn how to safely refactor code, without breaking the build.