Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to register custom html tags in Resharper?

I would like to use custom tags in my html files to include custom knockout components [1]:

<like-widget params="value: userRating"></like-widget>

I added the tag to the VisualStudio html formatting settings:

Tools > Options > Text Editor > HTML (Web Forms) > Formatting > Tag Specific Options

Resharper still does not recognize the custom tag and gives the warning

Cannot resolve tag "like-widget"

How do I tell Resharper to allow that specific tag without disabling the unknown tag warning? Is there some sort of setting file where I can register custom html tags?

Related article:

How to add custom HTML Tags to Visual Studio and Avoid Squiggly Lines

like image 498
Stefan Avatar asked Nov 18 '15 07:11

Stefan


2 Answers

It is not possible right now - there is a related ticket https://youtrack.jetbrains.com/issue/RSRP-434190.

like image 119
Alexander Kurakin Avatar answered Sep 18 '22 18:09

Alexander Kurakin


I would suggest to Disable the Inspection for Unknown HTML Tags as I indicated here:

Can I stop ReSharper objecting to Ionic HTML tags?

like image 20
VRPF Avatar answered Sep 22 '22 18:09

VRPF