@jahia/eslint-config

2.1.2 • Public • Published

Welcome to @jahia/eslint-config 👋

Version License: JAHIA'S DUAL LICENSING Twitter: Jahia

Provide Jahia ESLint shareable config to lint your JS projects.

Install

Add this package to the devDependencies of the project you intend to add ESLint to. This can be accomplished using yarn with the following command:

yarn add -D @jahia/eslint-config

or using npm with the following one:

npm i -D @jahia/eslint-config

Configure

Create a file named .eslintrc.json as a sibling of your package.json, with the following content:

```json
{
  "extends": "@jahia"
}
```

Update the scripts in your package.json to something like:

```json
{
  "build": "yarn lint && yarn webpack",
  "lint": "eslint --ext js,jsx .",
  "lint:fix": "eslint --ext js,jsx --fix ."
}
```

Additionally you may want to add a file .eslintignore as a sibling of your package.json, with the following content: node node_modules target build

Also depending on your need your can override some rules in the .eslintrc.json file by redefining them.

Many IDE support eslint configuration, do not forget to activate the option

Usage

If you added the scripts in your package.json, you can do:

yarn lint

or with npm:

npm run lint

Author

👤 Jahia

🤝 Contributing

Contributions, issues and feature requests are welcome!
Feel free to check issues page.

Show your support

Give a ⭐️ if this project helped you!

📝 License

Copyright © 2019 Jahia.
This project is JAHIA'S DUAL LICENSING licensed.


This README was generated with ❤️ by readme-md-generator

Dependencies (14)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i @jahia/eslint-config

    Weekly Downloads

    504

    Version

    2.1.2

    License

    MIT

    Unpacked Size

    6.45 kB

    Total Files

    6

    Last publish

    Collaborators

    • cmailleux
    • shuber
    • gflores-jahia
    • jahiaadmin
    • mdechecchi
    • jahia-ci