Skip to content

Commit 4424b67

Browse files
authored
feat(react): add some security linting (#10)
1 parent ba41253 commit 4424b67

File tree

3 files changed

+35
-2
lines changed

3 files changed

+35
-2
lines changed

package-lock.json

+30-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+3-1
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,11 @@
1919
"eslint-config-prettier": "9.1.0",
2020
"eslint-plugin-import": "2.29.1",
2121
"eslint-plugin-jsx-a11y": "6.8.0",
22+
"eslint-plugin-no-unsanitized": "4.0.2",
2223
"eslint-plugin-react": "7.34.0",
2324
"eslint-plugin-react-hooks": "4.6.0",
24-
"eslint-plugin-unicorn": "51.0.1"
25+
"eslint-plugin-unicorn": "51.0.1",
26+
"eslint-plugin-xss": "0.1.12"
2527
},
2628
"devDependencies": {
2729
"@commitlint/cli": "19.2.0",

src/configs/react.ts

+2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ export const react: ESLintConfig = {
88
'plugin:react/jsx-runtime',
99
'plugin:react-hooks/recommended',
1010
'plugin:jsx-a11y/recommended',
11+
'plugin:xss/recommended',
12+
'plugin:no-unsanitized/DOM',
1113
],
1214
settings: {
1315
react: {

0 commit comments

Comments
 (0)