Skip to content

Latest commit

 

History

History
58 lines (43 loc) · 917 Bytes

README.md

File metadata and controls

58 lines (43 loc) · 917 Bytes

eslint

Shared TypeScript Eslint config for my projects

Install

npm i -D @cycraft/eslint

It will install these packages for you, so you don't have to include them in your package dependencies:

  • @eslint/js
  • @types/node
  • eslint
  • eslint-config-prettier
  • eslint-plugin-unicorn
  • prettier
  • prettier-plugin-jsdoc
  • typescript
  • typescript-eslint

Usage

eslint.config.js

import config from '@cycraft/eslint/config'

export default config

.prettierrc.js

import prettier from '@cycraft/eslint/prettier'

export default prettier

Update Eslint Config

import config from '@cycraft/eslint/config'

export default [
  {
    ignores: ['**/dist/*'],
  },
  ...config,
  {
    files: ['**/*.js', '**/*.jsx', '**/*.ts', '**/*.tsx'],
    rules: {
      '@typescript-eslint/no-explicit-any': 'off',
    },
  },
]