对 Visual Studio 中的Resharper禁用对某种文件的检测

原因:在Visual Studio中安装Reshaper后,就会对各种文件进行代码检测,但是因为Reshaper更新的速度不是很及时,所以有时会对Visual Studio中某些新功能误断,导致Coding时各种红哗哗的错误

例如:

对 Visual Studio 中的Resharper禁用对某种文件的检测

因为Reshpaer对Razor中inject标识的误判,所以各种提示错误,这时可以想到的就是单独对cshtml关闭Reshaper

具体操作如下

菜单>Reshaper>Options…

然后展开 Code Inspection

Elements to skip中的 File masks中添加 *.cshtml

对 Visual Studio 中的Resharper禁用对某种文件的检测

这样在再次打开cshtml文件时就不会受到Reshaper的影响了

Original: https://www.cnblogs.com/chsword/p/visualstudio_disable_resharper_code_inspection.html
Author: 重典
Title: 对 Visual Studio 中的Resharper禁用对某种文件的检测

原创文章受到原创版权保护。转载请注明出处:https://www.johngo689.com/551419/

转载文章受原作者版权保护。转载请注明原作者出处!

(0)

大家都在看

亲爱的 Coder【最近整理,可免费获取】👉 最新必读书单  | 👏 面试题下载  | 🌎 免费的AI知识星球