Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What's the difference between this and https://github.com/SonarSource/eslint-plugin-sonarjs #31

Closed
CMCDragonkai opened this issue Nov 25, 2021 · 5 comments
Labels
question Further information is requested

Comments

@CMCDragonkai
Copy link

Are these 2 separate plugins?

@JounQin
Copy link
Member

JounQin commented Nov 25, 2021

There are some rules in SonarJS unavailable in eslint-plugin-sonarjs, so I extract rules in SonarJS to this project.

Take sonar/deprecation as example.

And you can see the rules list at https://github.com/rx-ts/eslint-plugin-sonar#rule-list and https://github.com/SonarSource/eslint-plugin-sonarjs#rules

@JounQin JounQin added the question Further information is requested label Nov 25, 2021
@CMCDragonkai
Copy link
Author

Does this work well with Typescript projects? I already have eslint rules applied with a few TS projects, I wanted to know if there will be conflicts.

@JounQin
Copy link
Member

JounQin commented Nov 25, 2021

It uses typescript inside as peer dependency, so it works well with TypeScript of course.

I wanted to know if there will be conflicts.

I think you should try it by yourself, I use it in my own and company projects, and it works well without conflict. And if you just find conflicts, you can easily disable one of the rules from it or other eslint plugins.

@JounQin JounQin closed this as completed Nov 25, 2021
@JounQin JounQin pinned this issue Nov 25, 2021
@CMCDragonkai
Copy link
Author

Cool but there seems to be some rules that are in sonarjs and not in this repo like for example https://github.com/SonarSource/eslint-plugin-sonarjs/blob/master/docs/rules/cognitive-complexity.md. I didn't see that mentioned in your README.md.

@JounQin
Copy link
Member

JounQin commented Nov 25, 2021

SonarJS and eslint-plugin-sonarjs are different, this plugin extracts rules from SonarJS which could be considered as additional rules.

So that short answer is you may want them both.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants