Skip to content

Commit

Permalink
feat: add npm publish pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
msobiecki committed Jul 17, 2023
1 parent e65b4c2 commit 737c47e
Showing 1 changed file with 87 additions and 14 deletions.
101 changes: 87 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,95 @@
# eslint-config

An ESLint shareable config for JavaScript/TypeScript ecosystem's.
[![npm version](https://badge.fury.io/js/%40msobiecki%2Feslint-config.svg)](https://badge.fury.io/js/%40msobiecki%2Feslint-config)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/msobiecki/eslint-config/blob/master/LICENSE)

// BASE
// base + best-practice
> Custom ESLint configuration for projects. It extends popular Airbnb ESLint config and other popular configs in one place.
// REACT
// react
// react-jsx
## Installation

// NEXT
// next
```bash
npm install --save-dev @msobiecki/eslint-config
```

// BASE JEST
// base jest
## Usage

// DOM JEST
// base jest + dom jest
To use this ESLint configuration, you need to extend it in your project's `.eslintrc` file:

// REACT JEST
// base jest + react jest
### base javascript/typescript configuration

```json
{
"extends": "@msobiecki/eslint-config"
}
```

### react javascript/typescript configuration

```json
{
"extends": [
"@msobiecki/eslint-config/react",
"@msobiecki/eslint-config/react-jsx"
]
}
```

### next configuration

```json
{
"extends": ["@msobiecki/eslint-config/next"]
}
```

### jest configuration

```json
# base
{
"extends": [
"@msobiecki/eslint-config/jest"
]
}

# dom
{
"extends": [
"@msobiecki/eslint-config/jest"
"@msobiecki/eslint-config/jest-dom"
]
}

# react
{
"extends": [
"@msobiecki/eslint-config/jest"
"@msobiecki/eslint-config/jest-react"
]
}
```

If you have an existing ESLint configuration, you can merge it with this configuration using the `extends` property:

```json
{
"extends": ["@msobiecki/eslint-config", "your-existing-config"]
}
```

Make sure to install the necessary peer dependencies as well:

- `eslint`
- `prettier`

## Contributing

Contributions are welcome! If you find any issues or have suggestions, please open an issue or submit a pull request.

Before submitting a pull request, please make sure to:

1. Run `lintstage` to ensure your changes adhere to the ESLint rules.

## License

This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.

0 comments on commit 737c47e

Please sign in to comment.