Socket
Socket
Sign inDemoInstall

eslint-plugin-sort-react-dependency-arrays

Package Overview
Dependencies
89
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    eslint-plugin-sort-react-dependency-arrays

ESLint plugin to alphabetically sort React hook dependency arrays


Version published
Weekly downloads
3.8K
increased by0.39%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

eslint-plugin-sort-react-dependency-arrays

ESLint plugin to enforce alphanumerically sorted React hook dependency arrays.

Works with --fix.

Installation

You'll first need to install ESLint:

npm i eslint --save-dev

Next, install eslint-plugin-sort-react-dependency-arrays:

npm install eslint-plugin-sort-react-dependency-arrays --save-dev

Usage

Add sort-react-dependency-arrays to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:

{
    "plugins": [
        "sort-react-dependency-arrays"
    ]
}

Then enable the rule under the rules section.

{
    "rules": {
        "sort-react-dependency-arrays/sort": "error"
    }
}

Keywords

FAQs

Last updated on 12 Sep 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc