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

using with eslint-plugin-security #1085

Closed
lakamsani opened this issue Mar 7, 2018 · 4 comments

Comments

@lakamsani
Copy link

commented Mar 7, 2018

Hi, is it possible to use standard.js and https://github.com/nodesecurity/eslint-plugin-security at the same time or do we have to switch back to eslint to check our code with Node Security Platform (nsp at https://nodesecurity.io/opensource).

@LinusU

This comment has been minimized.

Copy link
Member

commented Mar 7, 2018

That plugin seems amazing! I think we should investigate adding it by default 🚀

In the meantime, I would recommend you to use standardx which will allow you to add rules. Something like:

{
   "scripts": {
-    "test": "standard && mocha"
+    "test": "standardx && mocha"
   },
   "dependencies": {
     "standard": "^11.0.0"
+    "standardx": "^2.0.0"
+    "eslint-plugin-security": "^1.4.0"
   },
+  "eslintConfig": {
+    "plugins": [
+      "security"
+    ],
+    "extends": [
+      "plugin:security/recommended"
+    ]
+  }
}
@lakamsani

This comment has been minimized.

Copy link
Author

commented Mar 7, 2018

We tried that suggestion and it works great. Thank you.

@lakamsani lakamsani closed this Mar 7, 2018

@lakamsani

This comment has been minimized.

Copy link
Author

commented Mar 8, 2018

FYI, if anyone is trying this with WebStorm, it won't work from the editor thought it will from command line/npm script. Added an issue for Jetbrains (seller of WebStorm). https://youtrack.jetbrains.com/issue/WEB-31624

@LinusU

This comment has been minimized.

Copy link
Member

commented Mar 8, 2018

Opened an issue for adding the plugin to standard: #1086

@lock lock bot locked as resolved and limited conversation to collaborators Jun 6, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
2 participants
You can’t perform that action at this time.