resharper 8.1 compatibility to StyleCop - visual-studio-2013

I have VS2013, and want to work with resharper and style cop together in the IDE (have all the notifications of style cop, all the quick fixes together)
installed Resharper 8.1
Installed latest StyleCop-4.7.49.0
Configured my .csproj to work with stylecop and have build errors and all (straight from StyleCop settings). Copied to the .sln folder the Settings.StyleCop file.
However - Resharper don't recognize it - no notifications within the code, no mentioning in Resharper > Tools,
How can I make them speak with each other?

StyleCop 4.7.49 is not compatible with Resharper 8.1. The StyleCop - Resharper integration is not completely in sync with all the latest versions so to get full compatibility you need to run Resharper 8.2.
Specifically the version called:
ReSharper 8.2 (release date 2014-03-20) http://download.jetbrains.com/resharper/ReSharperSetup.8.2.0.2160.msi

Related

ESLint support Visual studio 2017

ESlint static intellisense doesn't seem to be supported in Visual Studio 2017 which makes coding in .js files a complete pain as I have to run the CMD eslint command to get any linting errors. In VSCode I can just use the ESLint extension. What about Visual studio 2017?
Is their any way I can enable it?
How to Get ESLint Working in Visual Studio 2019 and 2017:
2019 v16 & 2017 >= v15.8
I've included the previous version instructions at the end, but do yourself a favor and upgrade if you want this feature.
From the menu: Tools > Options > Text Editor > Javascript/Typescript > Linting
Check Enable Eslint
The global-in-visual-studio .eslintrc file is at your root user directory (Windows 10) along with other visual studio configs. You could still have eslint installed via npm install eslint -g on your machine. VS won't use it. It comes with the react plugin, but you can install other plugins and they'll will work. You can extend configs normally in your project (eslint ref)
It uses Eslint v4 but acc. to MS docs,
if your project has a local installation of ESLint, it will use that version instead
2017 v.15.7
From the menu: Tools --> Options --> Text Editor --> Javascript/Typescript
Set Enable Eslint to True (if it's not already)
Then from the main menu: Tools --> Web Code Analysis --> Edit ESLint Settings
You will have to save the .eslintrc and your.js file for the rules to take effect. There might be a way to enable the intellisense as you type, but I haven't found it. I found that if I update the rules after visual studio has already begin linting, I have to restart the project for the new rule to take effect. Still clunky but this is a great way to quickly implement a coding standard especially when you match it with your text editor format and use an auto-format on save plugin like this one
Just remember to edit the .eslintrc file in the ESLint 2.0.0 format found here
I don't know if this is part of the 15.8.2 update (just added on 8/23/18) or not, but the layout for Options has changed slightly:
As has the menu options under Web Code Analysis:
I suddenly started getting the most picayune errors from it (Like "Expected '===' and instead saw '=='.") which I suspect is due to it having been "improved" to work better.
The eslint version of Visual Studio is not the latest one, that's why you couldn't get the eslint to work as in VSCode.
There is an extension named VisualLinter which let you use the newer version of eslint.
As of 14/8/2018 eslint has much better support in Visual Studio 2017 (15.8.0)
https://learn.microsoft.com/en-us/visualstudio/releasenotes/vs2017-relnotes-v15.8#eslint-improvements

Visual Studio 2015 Enterprise with ReSharper 10 Ultimate -- Cannot be properly resolved

I have Visual Studio 2015 Enterprise, version 14.0.24720.00 Update 1 as well as ReSharper 10 Ultimate, version 10.0.2 installed. I have a typescript file that is using AtScript syntax to refer to the Angular2 directive module, as its annotation. However, ReSharper is stating the following error:
Symbol 'Directive' cannot be properly resolved, probably it is located in inaccessible module.
Below is the full error tooltip.
The application compiles and runs as expected, and the angular portions of the application also function as desired. It appears as though this is a ReSharper false negative. Is anyone familiar with a workaround other that simply disabling ReSharper or ignoring the warning?
The issue is simply a bug with the latest version of ReSharper, if you Suspend ReSharper the issue simply goes away and all the source code works as expected.
Update
This has since been addressed in the ReSharper 2016.1 version.
As a workaround, if you are using angular2 from your node_modules folder, then you can reference it directly instead of relying on the new node module resolution. For example you can do:
import {Directive} from '../../node_modules/angular2/core';
As of 02/2016, the issue is fixed in the ReSharper Ultimate 10.1 EAP 3
this version still has some other typescript issues though
Original answer, explaining why it couldn't work in previous versions:
Had the same setup and same issue. I strongly believe this is related to: "moduleResolution": "node"
https://youtrack.jetbrains.com/oauth?state=%2Fissue%2FRSRP-273158
Unfortunately, no way now. We're working on node.js support for the next ReSharper version.
If updating to latest ReSharper version does not work and this only affects .js(x) and .ts(x) files you only need to suspend those. You can do that by going to ReSharper -> Options -> Unclick JavaScript and TypeScript.
It could be Resharper problem. disable it from tools->option->Resharper Ultimate->General->Suspend Now and the errors will be hide.
I was getting the same problem on one of my modules on Resharper 2017.1 in Visual Studio 2017.
But after updating my Resharper to 2017.2.2, that solved the problem.

VS 2015 & vNext/MVC 6 IntelliSense issues - Resharper

I am having an issue with Visual Studio 2015 RC and IntelliSense when running the MVC6 vNext project template. The project builds and runs just fine and nuget restores packages if I manually remove them. The issue is that VS 'shows' that it cannot resolve my using statements throughout the project, thus breaking intellisense. Has anyone had this issue where it builds and runs fine but does not show the using statements as resolved?
OK, figured it out. Suspending resharper removed the red text, but still no intellisense. Tried to update resharper via the resharper menu in VS, this failed. Manually installed version 9.1.1 of resharper over version 9.0.0, this made everything happy again (full install removed previous version of resharper).
You need to use ReSharper 2016.2 or above to support .net core.
You can use the early access version available from https://confluence.jetbrains.com/display/ReSharper/ReSharper+2016.2+EAP
This is an issue of Resharper 9. Don't use Resharper 9 with MVC 6. It will suggest you the wrong path when you import CSS or JavaScript file to your page, as I said in this question.
So, the solution is: update to Resharper 10. However, there are many problem remains when using Resharper with MVC 6.

Reset Visual Studio default settings while retaining changes made by Resharper

I have a machine on which I had to use VS2010 for a project. I installed the project's VS settings (color scheme, formatting etc.) so that I'd be using the same environment as the other developers on the project.
I subsequently installed VS2012 for my own use - it picked up the settings (color, formatting) from the VS2010 install.
I then installed ReSharper into both.
I now want to remove the project's settings from my VS2012, while leaving them in the VS2010 install - I am still working on their project.
I was going to reset VS2012 to its default settings but I don't want to lose the changes that ReSharper makes.
Is there a way to do this, or do I have to uninstall ReSharper from VS2012 (or both if need be), reset the VS default settings, then resinstall ReSharper?
It's a hard question, since ReSharper is storing its keyboard shortcuts and fonts/colors settings among VS ones, though all other settings are stored separately (ReSharper | Manage Options...)
You may back up all R# settings in 'Manage options...' dialog. However, if you are going to import/export VS keyboard and fonts settings, VS won't allow you to select only resharper- prefixed options.
Hope this info helps, however I'm not sure if it suitable for you or not...
Thanks.
Alex Berezoutsky,
Senior Support Engineer,
JetBrains, Inc.
"Develop with pleasure!"

Resharper 6.0 code analysis and font configuration unavailable

After I uninstalled Resharper 5.0 and installed the latest 6.0, code analysis stopped working on VS 2010 (on vs 2008 it still works).
During investigation I noticed that Fonts and Colors is also not showing Resharper's items.
I tried clearing the Registry value at HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\10.0\FontAndColors\Cache and it didn't work.
I tried uninstalling 6.0, resetting VS's settings, reinstalling 6.0.
I tried then repairing the installation for 6.0.
I tried disabling stylecop plugin for resharper.
I tried clearing the cache for the solution I'm working.
I tried creating a new project to see if it was yet something else related to my project.
I tried looking at the VS startup log, resharper starts with no errors.
I tried uninstalling 6.0 and installing 5.0 again, 5.0 is still working with code analysis and has fonts and colors configuration.
New ideas are welcome.
Could you run Visual Studio with the following command line: 'devenv /ReSharper.LogFile C:\resharper_log.txt /ReSharper.LogLevel Verbose'.
After that, please create a new Class Library solution, verify the issue and send me a corresponding 'resharper_log.txt' file to "support[at]jetbrains.com".
Thanks.
Alex Berezoutsky,
Support Engineer,
JetBrains Inc.
"Develop with pleasure!"

Resources