ReSharper 2017.2 Help

Code Inspections in XAML

In XAML, ReSharper 2017.2 provides two kinds of code inspections: 18 inspections that detect errors such as broken syntax, unresolved symbols, compiler errors, etc. (you cannot configure or disable any of these inspections), and 46 proprietary code inspections, any of which you can disable or change its severity level.
These code inspections help you detect code issues in design time in all open files, and additionally they allow you to find code issues in specific scope.

Configurable XAML inspections are listed below, grouped in the following categories:

Code Notification (14 inspections)

This category groups code inspections with minor severity levels.
InspectionDefault Severity
{DynamicResource} can only be used with dependency property Error
Constructor not resolved Warning
Dependency property descriptor field missing Warning
Element name reference not resolved Error
Ignored path Disabled
Mapped path Hint
Member of invalid type Error
Object/markup extension of invalid type Error
Routed event descriptor field missing Warning
Static resource not resolved Warning
Unresolved binding path when DataContext is known Warning
Unresolved binding path when DataContext is unknown Hint
XAML resource of invalid type Error
XAML style of invalid target type Error

Common Practices and Code Improvements (3 inspections)

This category groups inspections that hunt for medium severity issues that mainly affect code readability.

Compiler Warnings (2 inspections)

Inspections in this section detect compiler warnings before you compile.
InspectionDefault Severity
Use of obsolete type or type member Warning
Use of obsolete type or type member (error) Error

Constraints Violations (1 inspection)

This category includes code inspections, mostly with the warning severity level, which detect violations related to symbol attributes, including ReSharper's code annotations, and other similar issues.
InspectionDefault Severity
Inconsistent Naming Warning

Potential Code Quality Issues (13 inspections)

This category includes inspections that detect critical issues (code smells), mostly with Error or Warning level. This category also includes inspections that ensure localization assistance.
InspectionDefault Severity
DeveiceFamily-specific view type name does not match generic type name Warning
Duplicate device family view Error
Duplicate style property/event setter Warning
Grid element column/row index is out of grid definition range Warning
Missing grid column/row setter for non-first child Warning
Non-accessed field (non-private accessibility) Suggestion
Non-accessed field (private accessibility) Warning
Path error Warning
RelativeSourceMode is not set explicitly Warning
Style target type is not convertible to base type Error
Unknown DeviceFamily Warning
x:Key is allowed for resources and dictionary elements only Error
XAML language level error Error

Redundancies in Code (11 inspections)

Code inspections in this category look for redundancies and dead code, which affect code readability and style, and could be safely removed. Some code redundancies cannot be fixed automatically, and quick-fixes for them are performed in the interactive mode, requiring the user input. But the majority of the redundancies can be fixed without user interaction, using either fix in scope or code cleanup.
InspectionDefault Severity
Property value is equal to style-provided Warning
Redundant empty collection property setter Warning
Redundant 'Freeze' attribute Warning
Redundant modifiers attribute Warning
Redundant name attribute Warning
Redundant namespace alias Warning
Redundant property type qualifier Warning
Redundant resource Warning
Remove redundant attached property setter Warning
Single grid row/column definition is redundant Warning
Single-cell grid column/row span is redundant Warning

Redundancies in Symbol Declarations (2 inspections)

This category includes code inspections, mostly with the warning severity level, which detect empty and unused symbol declarations.
Last modified: 12 October 2017