Inline Global Using refactoring
This refactoring allows you to replace one or more global using directives with local
using directives in all files where symbols from the corresponding namespaces are used.
In the example below, we apply this refactoring to
global using System.Collections; in file GlobalUsings.cs and as a result it adds the corresponding local using directives in files One.cs and Two.cs.
Inline a global using
Place the caret at a
global usingdirective or select multiple global using directives.
Do one of the following:
Press Control+Shift+R and then choose Inline Global Using.
Right-click and choose Refactor | Inline Global Using from the context menu.
Choosefrom the main menu.
ReSharper will add local
usingdirectives for selected namespaces to all files in the project where symbols from these namespaces are used, and remove the original
This feature is supported in the following languages and technologies: