Skip to content
RisXSS
Branch: master
Clone or download
Latest commit 7e06205 May 16, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs/rules
rules
test
.editorconfig
.gitignore
index.js
package.json
readme.md

readme.md

eslint-plugin-risxss

Various ESLint rules to prevent XSS

Install

$ yarn add eslint eslint-plugin-risxss --dev

Usage

Configure it in .eslintrc.js.

module.exports = {
  env: {
    browser: true,
    es6: true
  },
  extends: "eslint:recommended",
  parserOptions: {
    ecmaFeatures: {
      jsx: true
    },
    ecmaVersion: 2018,
    sourceType: "module"
  },
  plugins: ["react", "risxss"],
  rules: {
    "risxss/potential-xss": "error"
  }
};

Rules

License

MIT

You can’t perform that action at this time.