Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

    eslint-plugin-mutationpublic

    eslint-plugin-mutation

    Checks for mutations of objects. Allows a whitelist of mutable objects.

    Getting started

    Installation

    npm i --save-dev eslint-plugin-mutation

    Usage

    Add the following to your .eslintrc

    By default, "this" and "global" are allowed to be mutated.

      plugins: [
        "mutation"
      ],
      rules: {
        "mutation/no-mutation": 2
      }
    

    This can be customized.

      plugins: [
        "mutation"
      ],
      rules: {
        "mutation/no-mutation": [2, {exceptions: ["this", "that", "global", "window"]}]
      }
    

    Contributing

    Please submit a PR.

    install

    npm i eslint-plugin-mutation

    Downloadsweekly downloads

    2

    version

    1.0.0

    license

    ISC

    repository

    githubgithub

    last publish

    collaborators

    • avatar