@kodehort/eslint-config

6.0.0 • Public • Published

eslint-config

eslint-config is a curated set of ESLint configurations that are used across our projects and can be used in your projects too. It includes a set of rules that are designed to help you write clean, maintainable, and error-free code.

Installation

pnpm install eslint @kodehort/eslint-config -D

Usage

To use eslint-config, you need to extend it in your ESLint configuration file. Here's an example .eslintrc.cjs file:

import { baseConfig } from '@kodehort/eslint-config'

export default [
  // ... other flatConfig
  ...baseConfig,
  // project specific config
  {
    languageOptions: {
      parserOptions: {
        project: [
          './tsconfig.json',
          './tsconfig.eslint.json',
        ],
      },
    }
  },
  // ...
]

Package discovery and file resolution

The config will search for package.json files in the current or child folders. Each packjage.json file will be used to define a path for the eslint rules. The content of the file will be used to infer the project type and setup the appropriate eslint rules.

Readme

Keywords

none

Package Sidebar

Install

npm i @kodehort/eslint-config

Weekly Downloads

9

Version

6.0.0

License

MIT

Unpacked Size

21.7 kB

Total Files

28

Last publish

Collaborators

  • alistairstead