Giter VIP home page Giter VIP logo

eslint-plugin-cookbook's Introduction

@thibaudcolas/eslint-plugin-cookbook ESLint

npm Build status

Shareable ESLint config, based on airbnb/javascript, bundled as a plugin.

Why

We want shareable configs to have as low of an overhead as possible. Users shouldn't have to know exactly what plugins are required by the config, install them and manage their versions manually. This plugin contains a shareable config, with plugin dependencies automatically installed.

See eslint/eslint#3458 for further discussion on this topic.

Usage

Install ESLint and the config:

npm install --save-dev eslint @thibaudcolas/eslint-plugin-cookbook

Then configure ESLint to use this config. As a .eslintrc.js in the root of your project:

module.exports = {
  // https://github.com/thibaudcolas/eslint-plugin-cookbook
  extends: "plugin:@thibaudcolas/cookbook/recommended",
};

With Prettier

This recommended config is Prettier-compatible. First, install Prettier:

npm install --save-dev prettier

Then, to configure Prettier itself, create a prettier.config.js file in the root of your project. You can use the following to get started:

// https://github.com/thibaudcolas/eslint-plugin-cookbook
module.exports = require("@thibaudcolas/eslint-plugin-cookbook/prettier.config");

Switching to this config

Read on: Upgrading to a stricter ESLint config.

Overriding the rules

Should further customisation be required, rules coming from external plugins require the @thibaudcolas/cookbook prefix:

module.exports = {
  // https://github.com/thibaudcolas/eslint-plugin-cookbook
  extends: "plugin:@thibaudcolas/cookbook/recommended",
  rules: {
-    "react/react-in-jsx-scope": ["warn"],
+    "@thibaudcolas/cookbook/react/react-in-jsx-scope": ["warn"],
-    "import/prefer-default-export": ["warn"],
+    "@thibaudcolas/cookbook/import/prefer-default-export": ["warn"],
  },
};

Tips

Related tools

To get the most out of this config, it is assumed that projects have the following tools set up:

Rules

Extends

Cookbook config

Rules of airbnb

Disabled rules

eslint-plugin-cookbook's People

Contributors

renovate-bot avatar renovate[bot] avatar thibaudcolas avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

eslint-plugin-cookbook's Issues

The automated release is failing 🚨

🚨 The automated release from the master branch failed. 🚨

I recommend you give this issue a high priority, so other packages depending on you could benefit from your bug fixes and new features.

You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can resolve this 💪.

Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.

Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the master branch. You can also manually restart the failed CI job that runs semantic-release.

If you are not sure how to resolve this, here is some links that can help you:

If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.


The push permission to the Git repository is required.

semantic-release cannot push the version tag to the branch master on remote Git repository with URL https://[secure]@github.com/thibaudcolas/eslint-plugin-cookbook.

Please refer to the authentication configuration documentation to configure the Git credentials on your CI environment and make sure the repositoryUrl is configured with a valid Git URL.


Good luck with your project ✨

Your semantic-release bot 📦🚀

Dependency Dashboard

This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

Rate-Limited

These updates are currently rate-limited. Click on a checkbox below to force their creation now.

  • fix(deps): update eslint-plugin-react-hooks to v4.6.0
  • chore(deps): update node to v20
  • 🔐 Create all rate-limited PRs at once 🔐

Edited/Blocked

These updates have been manually edited so Renovate will no longer make changes. To discard all commits and start over, click on a checkbox.

Open

These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

Detected dependencies

github-actions
.github/workflows/ci.yml
  • actions/checkout v3
  • actions/checkout v3
  • actions/setup-node v2-beta
  • actions/cache v2
npm
package.json
  • eslint-plugin-react-hooks ^4.0.4
  • @commitlint/cli 16.2.3
  • @commitlint/config-conventional 16.2.1
  • @semantic-release/changelog 6.0.1
  • @semantic-release/exec 6.0.3
  • @semantic-release/git 10.0.1
  • danger 11.0.2
  • eslint-rule-documentation 1.0.23
  • jest 28.1.0
  • prettier 2.2.1
  • semantic-release 19.0.2
nvm
.nvmrc
  • node 16

  • Check this box to trigger a request for Renovate to run again on this repository

Action Required: Fix Renovate Configuration

There is an error with this repository's Renovate configuration that needs to be fixed. As a precaution, Renovate will stop PRs until it is resolved.

Error type: undefined. Note: this is a nested preset so please contact the preset author if you are unable to fix it yourself.

Additional plugins to consider for inclusion

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.