Skip to content

CyCraft/eslint

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

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',
    },
  },
]