Skip to content

Commit

Permalink
fix: include base config
Browse files Browse the repository at this point in the history
  • Loading branch information
MatthewPattell committed Feb 29, 2024
1 parent 43b8b6b commit c3e867c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 7 deletions.
11 changes: 9 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# eslint-config-react

This package provides Lomray base JS (Typescript) .eslintrc as an extensible shared config for React.
This package provides Lomray eslint config as an extensible shared config for React.

## Usage

Expand All @@ -10,4 +10,11 @@ This package provides Lomray base JS (Typescript) .eslintrc as an extensible sha
npm i --save-dev @lomray/eslint-config-react
```

2. Add `extends: ["@lomray/eslint-config-react"]` to your .eslintrc.
2. Add config to your `eslint.config.js`
```js
import lomrayConfig from '@lomray/eslint-config-react';

export default [
...lomrayConfig.recommended,
];
```
8 changes: 4 additions & 4 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@ import react from './configs/react.js';
import reactHooks from './configs/react-hooks.js';
import jsx from './configs/jsx-a11y.js';

const current = [
const reactConfig = [
react,
reactHooks,
jsx,
];

export default {
recommended: [
baseConfig,
...current,
...baseConfig.recommended,
...reactConfig,
],
react: current,
react: reactConfig,
};
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@lomray/eslint-config-react",
"version": "5.0.1",
"version": "5.0.2",
"description": "This package provides Lomray eslint config as an extensible shared config for React.",
"main": "index.js",
"type": "module",
Expand Down

0 comments on commit c3e867c

Please sign in to comment.