-
Notifications
You must be signed in to change notification settings - Fork 1
Add jest & mocha eslint plugins #207
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
base: development/8.3
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -17,7 +17,9 @@ | |
| }, | ||
| "dependencies": { | ||
| "commander": "11.1.0", | ||
| "markdownlint": "0.31.1" | ||
| "markdownlint": "0.31.1", | ||
| "eslint-plugin-jest": "^28.11.0", | ||
| "eslint-plugin-mocha": "^10.5.0" | ||
|
Comment on lines
+21
to
+22
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. need to be added to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. as we don't need both, they should go in
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. if we don't add it to The There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. But that's the point that we don't want to automatically add it by default, it should be the source repo that picks if it wants to install the plugin jest or mocha based on what it needs to avoid unnecessary dependency. But maybe they are small enough to ignore an extra unused dependency.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I would rather it "just works", and the dependencies are added automatically ; but indeed they may pull quite a few deps. Maybe we actually already have everything, so not much difference; but I am not sure... I will double check how much gets pull. The only "safeguard" of sorts is that this is this whole package is a dev dependency, so will not have any effect on prod. That said, if we do not have the dependencies, the user (dev) experience will not be very good : unless the appropriate plugin is explicitely specified, then eslint will most likely fail to run with a cryptic message (or worse, the extra check will silently not be performed) |
||
| }, | ||
| "devDependencies": { | ||
| "eslint": "^9.9.1" | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe too strong, causes lots of errors...
→ just "mocha/no-exclusive-tests" and "jest/no-focused-tests" ?
→ or extend recomended plugins, then disable a few (no arrow...)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we can review on some repos what errors this produces and agree on the rules we want to disable? Hopefully not too many, as relaxed rules tend to cause heterogeneous code styles across our projects...
Some are quite obvious to disable, the others, if their number is ok, should be kept. We might as well generalize prettier, so it automates most of the work...