# eslint-config-prettier-react

> ESLint and Prettier Config

Latest version **0.0.24** (published 2019-07-28) · MIT license · 0 weekly downloads

## Install

```sh
npm install eslint-config-prettier-react
pnpm add eslint-config-prettier-react
yarn add eslint-config-prettier-react
bun add eslint-config-prettier-react
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.24 |
| Published | 2019-07-28 |
| First published | 2019-05-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 5.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Maintainers | kuromizu |
| Keywords | javascript, ecmascript, eslint, lint, config, prettier |

## Links

- npm: https://www.npmjs.com/package/eslint-config-prettier-react
- Repository: https://github.com/mifas/eslint-config-prettier-react
- Homepage: https://github.com/mifas/eslint-config-prettier-react#readme
- Issues: https://github.com/mifas/eslint-config-prettier-react/issues
- npm.io page: https://npm.io/package/eslint-config-prettier-react

## Alternatives

- [eslint-plugin-sonarjs](https://npm.io/package/eslint-plugin-sonarjs.md) — 2.9M weekly downloads
- [eslint-config-expo](https://npm.io/package/eslint-config-expo.md) — 1.5M weekly downloads
- [@matter/protocol](https://npm.io/package/@matter/protocol.md) — 63.5K weekly downloads
- [@eventcatalog/linter](https://npm.io/package/@eventcatalog/linter.md) — 24.8K weekly downloads
- [@inrupt/eslint-config-base](https://npm.io/package/@inrupt/eslint-config-base.md) — 4.5K weekly downloads

## Recent versions

- 0.0.24 (latest) — 2019-07-28
- 0.0.23 — 2019-07-28
- 0.0.22 — 2019-07-23
- 0.0.21 — 2019-05-19
- 0.0.20 — 2019-05-13
- 0.0.19 — 2019-05-13

## README

## Forked from [wesbos](https://github.com/wesbos/eslint-config-wesbos)

## Local / Per Project Install
1. Run below code
```
npx install-peerdeps --dev eslint-config-prettier-react
```

2. You can see in your package.json there are now a big list of devDependencies.

3. Create a `.eslintrc` file in the root of your project's directory (it should live where package.json does). Your `.eslintrc` file should look like this:

```json
{
  "extends": [
    "prettier-react"
  ]
}
```
4. ⚠️⚠️⚠️ Delete `eslintConfig` in the package.json
   
Tip: You can alternatively put this object in your `package.json` under the property `"eslintConfig":`. This makes one less file in your project.

1. You can add two scripts to your package.json to lint and/or fix:

```json
"scripts": {
  "lint": "eslint .",
  "lint:fix": "eslint . --fix"
},
```

## Global Install

1. First install everything needed:

```
npx install-peerdeps --global eslint-config-prettier-react
```

2. Then you need to make a global `.eslintrc` file:

ESLint will look for one in your home directory

* `~/.eslintrc` for mac
* `C:\Users\username\.eslintrc` for windows

In your `.eslintrc` file, it should look like this:

```json
{
  "extends": [
    "prettier-react"
  ]
}
```

3. To use from the CLI, you can now run `eslint .` or configure your editor as we show next.

## With VS Code

  ```js
  "editor.formatOnSave": true,
  "[javascript]": {
    "editor.formatOnSave": false
  },
  "[javascriptreact]": {
    "editor.formatOnSave": false
  },
  "eslint.autoFixOnSave": true,
  "prettier.disableLanguages": ["javascript", "javascriptreact"],
  ```

## With Create React App

1. You gotta eject first `npm run eject` or `yarn eject`
1. run `npx install-peerdeps --dev eslint-config-prettier-react`
1. Crack open your `package.json` and replace `"extends": "react-app"` with `"extends": "prettier-react"`

---
_Source: https://npm.io/package/eslint-config-prettier-react · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
