Лучшие ide для c#-разработчика
- Localization Manager
- F# Support
- Manage setting layers
- View changes history for a file or selection
- Add external files and folders
- What is EditorConfig and how does JetBrains Rider extend it?
- Create HTTP request files
- Plugin packaging
- User Experience
- Language Support
- F# support
- Default settings and setting layers
- Conditional line breakpoints
- Version Control
- Front-End Development
The Localization Manager is now available in Rider to help you localize your .NET application or
website. You can access it using the Tools menu or by double-clicking on a .resx file.
It allows you to view everything contained in all your project’s files, or a
specified selection of files, in a single grid.
You can easily find all resources that are missing localized values or are just not used.
You can add, edit, rename, search for, find usages of, and safely delete any localized
You can easily add a new culture to your application using the predefined list of cultures
in the completion list or hide locales you don’t need right now.
You can export the whole grid to a CSV format to share with translators and import the final
version back into the Localization Manager.
You can add and edit comments for any entity from resource files right inside the grid, and
you can also export and import these comments.
Postfix templates in code completion
Postfix templates can help you transform expressions that you have already
typed without jumping backward. We’ve finally introduced them for F#, starting
with the template.
Rider has a new action for pattern deconstruction for F# and
Actions for rearranging the code are now available. You can move elements
up / down or left / right in enum or union cases, record or union case
fields, match clauses, tuples, and function parameters.
Another new action, Optimize Imports, will free you from the need to manually
trigger a similar quick-fix on warnings each time you need to clean imports.
New Debugger API
The new release comes with the new debugger API which has been largely rewritten. This is
not noticeable from the UI, but it allows more features to come and allows plugins to hook
into the debugging process as never before. This includes improved super-lazy value
calculations with better interruption and custom value representations. The only thing
noticeable from the outside is that debugger tool windows show the correct icons for all
Data breakpoints Windows only
Data breakpoints are useful when you need to focus on a particular object’s properties. You
typically use them in scenarios where you know what will change, but have no idea where the
change comes from in your codebase. This will be accessible from the Watch tool window, and
will even work with array elements. Due to current platform limitations, this feature is only
available for .NET Core 3+ on Windows.
Manage setting layers
By default, you can share JetBrains Rider settings per solution using the ‘Solution team shared’ layer — the only thing you need to do is to put the *.dotSettings file under version control. If you want to share settings in other ways, you would need to learn how to create new setting layers, import and export them. For these purposes, JetBrains Rider provides the Settings Layers dialog, available in the Settings dialog (by clicking the Manage Layers button).
Custom setting layers are added under existing default layers. For example, if you want the settings from the custom layer to be applied for all solutions, add it under ‘This computer’ layer; otherwise add it under one of the solution-specific layers depending on whether you want it to override the team-shared settings or not.
As soon as a custom setting layer is added, it appears in the Save selector in the Settings dialog, using which you can save modified settings to the custom layer. You can also modify settings in this layer by .
As an alternative to saving modified settings to a specific layer using the Save selector in the Settings dialog, you can open a specific setting layer for editing.
You can export a specific subset of settings from any setting layer to a new settings file. This file can be then used on another instance of JetBrains Rider to apply these settings.
As an alternative to , you can copy a subset of settings from this custom layer to one of the existing default or custom layers.
JetBrains Rider also allows you to copy a subset of settings from one mounted setting layer to another.
If necessary, you can clear all settings saved in a specific layer. To do so, right-click the layer and click Reset in the context menu.
You can also disable custom setting layers temporarily by clearing check boxes next to them or unmount a specific custom setting layer by right-clicking on it and selecting Remove in the context menu.
View changes history for a file or selection
JetBrains Rider allows you to review changes made to files or even fragments of source code. The Show History and the Show History for Selection commands are available from the main VCS menu and from the context menu of files.
The change history for a file is displayed in the dedicated History tab of the Repository tool window Alt+9.
You can use the toolbar buttons to compare the selected revision with the local version, compare classes from the selected revision, checkout the selected revision from your VCS, annotate the selected revision, and so on:
|Item||Tooltip and Shortcut||Description|
|Refresh||Click this button to refresh the current information.|
|Click this button to compare the selected revision of a file with its previous revision in the Differences Viewer.|
Show All Affected Files
|Click this button to open the Paths Affected in Revision dialog where you can view all files that were modified in the selected revision.|
|Show All Branches||Click this button to display changes from branches other than the current one.|
|Presentation Settings||Click to choose the amount of information you want to see in the History view. You can also select the Show Commit Timestamp option if you want JetBrains Rider to show the commit timestamp instead of the time when a change was authored.|
|Configure Layout||Click to choose the type of info you want to see:
|Open in GitHub||Click this button to open the page that corresponds to the selected commit on GitHub.|
Add external files and folders
With Rider, you can extend solutions by adding external files and folders. For example, you can have your test data, logs, or any other files and folders right next to your solution. These additional items in the solution are not saved in project or solution configs, but rather in Rider’s own settings.
External items in the solution are indexed by Rider, so you can enjoy instant search Ctrl+Shift+F and navigation Ctrl+T among other things for those items. However, external solution items will stay beyond the scope of your solution when you perform any of the solution-wide refactorings. For external solution items that share their VCS root with the solution, all version-control features will also be available.
To add an external folder to the current solution, right-click the solution in the Explorer window, choose Add | Attach Existing Folder, and then select a folder. The folder will appear in the Solution Explorer marked as attached:
Please note the difference between attaching external folders to your solution and adding existing files/folders/projects to your solution. The latter is done by choosing Add | Add Existing Project from the context menu on the solution or solution folder, or by choosing Add | Add Existing Item from the context menu on a project or folder — these kinds of modifications are saved in solution and project configs so you will also see the added items if you open the solution in Visual Studio.
When working with external items in the extended solution, note the following:
What is EditorConfig and how does JetBrains Rider extend it?
EditorConfig is a configuration file convention that is used to define and maintain consistent code styles between team members working on the same code as well as between different editors and IDEs that they might use. The styles are saved in INI-like files named .editorconfig, where section names are file masks and properties inside a section define code styles for files matching that masks.
As EditorConfig convention suggests, JetBrains Rider will apply code styles defined in files named .editorconfig in the directory of the current file and in all its parent directories until it reaches the root filepath or finds an EditorConfig file with . File masks specified in .editorconfig files, for example are also taken into account.
JetBrains Rider understands , most frequently used , and provides a set of custom EditorConfig properties, which allow for much more granular configuration of formatting, syntax, and code inspection rules — in fact, each code style preference that you can configure in the JetBrains Rider settings dialog has its own EditorConfig property. This means that you can maintain the entire configuration of code style and inspection rules in EditorConfig files. Below is an example of EditorConfig properties supported by JetBrains Rider:
Create HTTP request files
You can work with HTTP requests either from scratch files or from physical files of the HTTP Request type. Each file can contain multiple requests, and you can create as many files as needed.
Scratch files can be used to test HTTP requests during development. Scratch files are not stored inside a project, so JetBrains Rider can modify them and add additional information about the request. When an HTTP request is executed from a scratch file, the link to the response output file is added below the request and at the top of the file.
Physical files can be used for documenting, testing, and validating HTTP requests. Physical files are stored inside your project, and JetBrains Rider will not modify them. When an HTTP request is executed from a physical file, this file is not modified. Information about the executed request with the link to the response output file is added to the top of the file.
We’ve implemented structural removal of code – select and delete code with
any kind of structural selection (such as
extend/shrink selection, or rearrange code) and let Rider perform the remaining
structural modifications. You can remove commas and colons for method call
arguments, parentheses in attribute arguments, or braces for empty object
We’ve updated how Quick Documentation is shown. Attributes are now highlighted,
so they are easier to read and explore. If you’re inspecting any class or method
that uses generics, Rider no longer renders a placeholder value – the concrete
implementation is shown instead.
Rider plugins are simple ZIP archives containing metadata about the plugin, ReSharper extensions (DLL) and/or IntelliJ extensions (JAR). The content is structured like this:
Among other declarations, the must provide common metadata about its id, name, version, and frontend dependencies:
For simple plugins that don’t contain code that is specific to Rider, we might choose to manually pack the archive. However, this requires us to also manually update the tag according to the About JetBrains Rider dialog. Also note that archives created using .NET capabilities (like or PowerShell’s ) might not work.
For more complex plugins as well as for better testability, it is recommended to have a dedicated . This will also automatically take care of updating the tag.
Import Settings from other IDEs
Are you a first-time Rider user? If you’ve never installed or used Rider before,
the Welcome wizard now lets you import settings from other IDEs such as Visual
Studio, Visual Studio for Mac, or Visual Studio Code.
In addition, Rider will recognize settings from ReSharper.
Read more about
how importing settings from other IDEs works.
Organize tool windows by drag and drop
It is now easier to drag a tool window to the desired place within the main
IDE window or in a separate window. You can drag it by clicking and holding
the tool window name bar and dropping it in any highlighted area.
Transparent title bar
The title bar is now transparent on macOS when the IDE window isn’t in
Full-Screen Mode. It means that there is no visible border between the
title bar and the rest of the window.
If you need to configure use-case-specific options in Rider, you can do it in
the new Advanced Settings node in Preferences/Settings. For example,
you can add a left margin in Distraction-free mode, or set the caret
to move down after you use the Comment with Line Comment action.
C# Code Analysis
Do you use temporary variables to swap variable values? There is now a more elegant
way to do this! Rider 2021.2 can help you modernize your code with the new Swap
via deconstruction quick-fix.
Reduce the number of allocations in your code, and increase throughput!
Replace empty array creation with .
If you’re allocating a new , Rider will suggest using
to make memory usage more efficient.
If specific are not required, Rider can replace
Use the generated_code property from .editorconfig to mark
files or folders as generated code and exclude them from processing.
Code analysis is now faster for members with lots of local functions
Enjoy performance improvements in Find similar issues and code
analysis for large and complex switch statements and switch
Nullable Reference Types (NRT)
Do you have lots of nullable warning suppressions in your code base after
enabling nullable reference types?
Rider indicates suppressions () that are no longer needed and can be safely removed.
A new context action lets you search for all nullable warning suppressions
in scope. From the Find Results tool window, you can then re-evaluate
whether the suppressions are needed or not.
We’ve introduced a new refactoring to change nullability. It’s available as a
quick-fix, through the Refactor This action, or through an in-place refactoring when
adding or removing the nullable annotation ().
Rider will update nullability annotations and suggest propagating the changes
throughout your codebase.
Several new inspections with corresponding quick-fixes are available for
when you’re using JetBrains.Annotations attributes and nullable
reference types are enabled.
Update JetBrains.Annotations attributes to NRT syntax and
compiler-supported attributes! For example, Rider can update
Rider will inform you about redundant JetBrains.Annotations attributes,
such as or .
And of course, it will offer a quick-fix to update your code.
When the type annotation syntax is not allowed, a new inspection with a
quick-fix adds compiler-supported annotations, e.g.:
(in C# 8, where the
syntax is not allowed)
Rider adds new inspections and quick-fixes to help you with using
compiler-supported annotations such as ,
, , and .
A new inspection detects redundant compiler annotations, such as when
is applied to a nullable type, and a quick-fix
When nullable reference type syntax can be used, Rider will suggest doing so.
There are additional improvements that also deserve a mention:
Rider checks whether variables need to be nullable and produces stricter
types when possible.
Many context actions, quick-fixes, and postfix templates have been updated
to work better with nullable warning suppressions. They either preserve
nullable warning suppressions or produce them for introduced code if the
original code suppressed the warning.
- We’ve improved support for using generics with nullable reference types.
Learn more at
What’s New for C# nullable reference types in ReSharper and Rider 2021.2.
Source Generator support
Source Generators can be used to reduce tedious and repetitive development work,
and to generate code at compile time. In Rider 2021.2, many of the features
available for human-written code files are available for source-generated
files as well. We’ve improved editor support and added support for refactorings.
Refactorings can now be triggered from source-generated files. Use the
Rename refactoring to rename a generated property. Rider will also
rename the related symbol in manually written code!
Similarly, Change Signature lets you verify whether code that will be
generated after the change can still be compiled.
You can now use Find Usages, search for inheritors, navigate from
generated code to manually written code with Ctrl+Click and
Navigate To, and more.
Semantic highlighting is enabled so that class members like events, fields,
and properties are highlighted correctly. All
are shown where appropriate.
The Introduce Variable refactoring is now available for expressions. When invoked,
it shows the suitable subexpressions (unless a specific part of code is selected) and offers
to replace similar subexpressions. It is also smart about naming the new variable, and
suggests a meaningful name according to type and context.
Rename now works on underscore wildcards. Whenever you need to turn a wildcard
pattern into a named variable, you can call the refactoring instead of doing it
manually. It also takes type and context into account when suggesting names.
Quick fixes and context actions
has been significantly improved. It now works in more cases and keeps the
parameter count in mind when suggesting a type. Rider can now also suggest referencing a
module or another project from your solution and import the type from it.
Several new quick-fixes have been added as well: adding parentheses to an application of a
function in the list of parameters, adding the attribute to a containing type or
module, fixing syntax errors, converting let to use, and others.
We’ve implemented a fast redundant qualifiers analyzer, as well as a corresponding quick-fix
to remove the redundancies.
There’s now more options for highlighting various symbols differently. In addition, type
abbreviations are highlighted as the types they abbreviate, and functions can be highlighted
as methods. Both are external contributions, and we thank Igor Bagdamyan for them.
Rider now has type hints for expressions in chains. They help you keep track of what’s
happening without having to follow the whole chain in your mind. This too is an external
contribution, which we’d like to thank Saul Rennison
Color references are now highlighted in the code, making them more visible.
Rider boasts 2,200+ live code inspections, with automated quick-fixes to resolve detected issues individually or in bulk. Solution-wide error analysis will monitor code issues and let you know if anything goes wrong, even in files that are not currently open.
Rider’s rich editor features different kinds of code completion and code templates, auto-inserting matching braces and import directives, quick info tooltips and gutter icons for inheritance navigation, context actions, and much more.
Most of ReSharper’s 60+ refactorings are already available in Rider, and its 450+ context actions are all there. Rename, extract methods, interfaces and classes, move and copy types, use alternative syntax, and a lot more!
Unit test runner
Rider helps you run and debug unit tests based on NUnit, xUnit.net, or MSTest. You can explore tests, group them in different ways, break them down into individual sessions, see test output and navigate to source code from stack traces.
Debugger and more tools
Rider includes a debugger that works with .NET Framework, Mono and .NET Core applications, letting you step, watch, evaluate, and run to cursor. Other tools include a stack trace explorer, NuGet browser, and VCS and database support.
Databases and SQL
Work with SQL and databases without leaving Rider. Connect to databases, edit schemas and table data, run queries, and even analyze schemas with UML diagrams.
Jump to any file, type, or member in your code base instantly, as well as quickly find settings and actions. Find usages of any symbol, or navigate from a symbol to the base and derived symbols, extension methods, or implementations.
True to its roots, Rider supports a wide array of plugins developed for ReSharper and IntelliJ Platform. In addition to the bundled plugins (such as those for VCS, F#, and Unity support), plugins that support Markdown, files, and Python scripts are available.
Default settings and setting layers
Out of the box, JetBrains Rider comes with the default set of preferences, which are based on conventions and best practices in the .NET world. These default settings are hard-coded in the product and you can always reset to the defaults if necessary. If you change any layer-based settings, your change is saved in a settings layer and JetBrains Rider applies it overriding the corresponding default setting. Initially, JetBrains Rider suggests three layers, in which you can save your preferences: This computer, Solution team-shared, and Solution personal.
Consider the illustration below. You can see that initially all setting layers are empty and therefore JetBrains Rider can ‘see through them’ and apply the default settings:
JetBrains Rider is the first tool I install after repaving my development machine.
I haven’t launched Visual Studio for months after I switched to JetBrains Rider.
Working with branches has never been so smooth since I started using JetBrains Rider.
Dennis Doomen,Continuous Improver at Aviva Solutions and author of Fluent Assertions
JetBrains Rider is my C# development tool of choice these days on both OS X and Windows. If you’re a longstanding ReSharper user, you’ll find it to be an almost seamless transition. I highly recommend the developer-friendly keystroke navigation and fine grained debugger support.
In Rider, I just focus on working with my code, as it should be, instead of fighting my IDE. Rider gave me back the joy in writing .NET code.
Frans Bouma,lead developer, LLBLGen Pro
Switching to JetBrains Rider was a great decision. Our team has never experienced an IDE that can communicate with Unity in such a flawless and efficient manner. We would highly recommend JetBrains Rider to anyone who aims at improving the efficiency and accuracy of their workflows.
An IDE can make or break a developer’s day. When JetBrains introduced Rider (C#) we jumped on board as fast as we could. Having been there at every step of the way in Unity’s evolution of IDE integrations; working with Rider has been nothing but an absolute joy. With the introduction of CLion (C++), we were so excited we created an integration plugin for Unreal. Both of these tools help our team on a daily basis, allowing developers to perform their tasks quickly and efficiently, all the while seamlessly integrating with numerous parts of our pipeline.
Really pleased with how well JetBrains Rider works on my MacBook. It’s blazingly fast and the debugging experience in C# is at least as good as Visual Studio. Also, it gives me all the benefits of ReSharper out of the box! Loving it. Thanks JetBrains for another great product!
Conditional line breakpoints
The debugger allows you to set a condition, under which a particular breakpoint will be hit. This may be helpful, for example, if you want to see how your program behaves when a variable takes a certain value.
If the expression evaluates to , the breakpoint is hit. For instance, in the example below, the breakpoint will be hit only if .
For simple conditions, when all you need is to trigger the breakpoint after a certain number of hits (for example, if a breakpoint is inside a loop), you can use its Hit count property. In the example below, the program will be suspended on each breakpoint hit which is a multiple of two, that is 2, 4, 6, 8, and so on.
For quite a while now, Rider has been using Default Changelist as
the name for the node that stores all uncommitted changes. In this release,
we’ve decided to make the phrasing more precise by using the word
Changes instead. This update will affect your new projects.
Rider will no longer add changelists automatically for Git operations. So, for
example, cherry-pick won’t trigger a changelist creation.
However, if you still prefer automatic creation over the new behavior, you can
activate the former in Preferences/Settings | Version Control | Changelists
by ticking the Create changelists automatically checkbox.
Text search in Local History revisions
We’ve added a search field to the Local History dialog to help you quickly
get to the necessary text in your Local History revisions. Now, when you
right-click on any changed file and select Local History | Show History
in the context menu, you can quickly navigate around your file history by typing
the query in this field.
It is now possible to enable Git commit signing with GPG via
Preferences/Settings | Version Control | Git. If it is your first time
using a GPG key, you will first need to configure it. With an existing
preconfigured GPG key, you just need to select it from the drop-down list.
Reload pages in browser on save
If you preview HTML files in the browser, they will automatically update in
accordance with the saved changes in your HTML file or the linked CSS and
Rename refactoring for React useState hooks
You will no longer need to waste time on refactoring useState values and
functions one by one – Rider can now rename both for you! Place the caret
on a state value and press Shift+F6 or go to
Refactor | Rename from the right-click context menu.
Did you know that Rider can add missing import statements as you complete
ES6 symbols? Now it can do the same for CommonJS modules, too –
imports will be inserted on code completion.