Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@thebestco/eslint-config

Package Overview
Dependencies
Maintainers
2
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@thebestco/eslint-config

The BestCompany's shared eslint config

  • 2.1.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
16
increased by128.57%
Maintainers
2
Weekly downloads
 
Created
Source

BestPrice's eslint-config

This package provides BestPrice's .eslintrc as an extensible shared config.

It's basically a clone of Airbnb's same project with different and more rules and some other minor changes

How to update

  1. git commit -am …
  2. npm version patch
  3. git push
  4. npm publish

Usage

We export four ESLint configurations for your usage.

@thebestco/eslint-config

Our default export contains all of our ESLint rules, including EcmaScript 6+ and React. It requires eslint and eslint-plugin-react.

  1. npm install --save-dev @thebestco/eslint-config eslint-plugin-import eslint-plugin-react eslint-plugin-jsx-a11y eslint-plugin-react-hooks@next babel-eslint eslint
  2. add "extends": "@thebestco" to your .eslintrc

@thebestco/eslint-config/base

Lints ES6+ but does not lint React. Requires eslint.

  1. npm install --save-dev @thebestco/eslint-config eslint-plugin-import babel-eslint eslint-plugin-react-hooks@next eslint
  2. add "extends": "@thebestco/eslint-config/base" to your .eslintrc

@thebestco/eslint-config/legacy

Lints ES5 and below. Only requires eslint.

  1. npm install --save-dev @thebestco/eslint-config eslint
  2. add "extends": "@thebestco/eslint-config/legacy" to your .eslintrc

@thebestco/eslint-config/prettier

Prettier is a high opinionated powerful automatic formatter. Eslinter is a code quality tool. They can both live together but there are some compromises we have to do. We should disable all the es-rules that are effecting the code formating and interfere with the prettier.

The prettier setup contains the default export extended with the formating rules that interfere with the prettier. It requires eslint and eslint-plugin-react, as it is in the default configuration.

  1. npm install --save-dev @thebestco/eslint-config eslint-plugin-import eslint-plugin-react eslint-plugin-jsx-a11y eslint-plugin-react-hooks@next eslint-plugin-react-refresh babel-eslint eslint
  2. add "extends": "@thebestco/eslint-config/prettier" to your .eslintrc

If you want to have eslint installed globally, i.e running eslint in terminal (CLI)

npm install -g eslint
npm install -g babel-eslint
npm install -g eslint-plugin-react
npm install -g eslint-plugin-import
npm install -g eslint-plugin-jsx-a11y
npm install -g eslint-plugin-react-hooks@next
npm install -g eslint-plugin-react-refresh
npm install -g @thebestco/eslint-config

Additional notes

  • Remove the args from yours sublimeLinter config so that the local .eslintrc as honored
  • Make sure you add any additional rules and constants to .eslintrc that are specific to the project
  • Make sure an .eslintignore is in place so that you target your eslint where needed
  • Run eslint . --fix when you have your eslint in place to fix those easy to fix errors

FAQs

Package last updated on 31 Oct 2023

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc