Skip to content

Eslint Airbnb config is not compatible with Vuex. #883

Closed
@wujekbogdan

Description

@wujekbogdan

no-param-reassign rule makes the Airbnb Eslint config incompatible with Vuex. In Vuex parameters mutation is required - this is how Vuex works.

So In order to fix this issue, the following override is needed:

"no-param-reassign": [
  "error",
  {
    "props": true,
    "ignorePropertyModificationsFor": [
      "state",
      "acc",
      "e",
      "ctx",
      "req",
      "request",
      "res",
      "response",
      "$scope"
    ]
  }
],

PS
All properties except state are in the ignorePropertyModificationsFor array by default.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions