{"id":28281987,"url":"https://github.com/lexborisoff/eslint-plugin","last_synced_at":"2026-02-08T03:07:17.841Z","repository":{"id":268796562,"uuid":"897654819","full_name":"LexBorisoff/eslint-plugin","owner":"LexBorisoff","description":"ESLint Plugin","archived":false,"fork":false,"pushed_at":"2025-07-02T00:22:41.000Z","size":205,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"dev","last_synced_at":"2025-10-10T08:25:58.088Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"isc","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LexBorisoff.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"license","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-12-03T02:14:48.000Z","updated_at":"2025-07-02T00:22:39.000Z","dependencies_parsed_at":"2024-12-19T01:25:44.029Z","dependency_job_id":"f8d4e39a-eb9f-491f-810b-22c3eacd8fac","html_url":"https://github.com/LexBorisoff/eslint-plugin","commit_stats":null,"previous_names":["lexborisoff/eslint-plugin"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/LexBorisoff/eslint-plugin","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LexBorisoff%2Feslint-plugin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LexBorisoff%2Feslint-plugin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LexBorisoff%2Feslint-plugin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LexBorisoff%2Feslint-plugin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LexBorisoff","download_url":"https://codeload.github.com/LexBorisoff/eslint-plugin/tar.gz/refs/heads/dev","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LexBorisoff%2Feslint-plugin/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29218665,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-08T02:25:35.815Z","status":"ssl_error","status_checked_at":"2026-02-08T02:24:27.970Z","response_time":57,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-05-21T12:14:17.463Z","updated_at":"2026-02-08T03:07:17.827Z","avatar_url":"https://github.com/LexBorisoff.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# `@lexjs/eslint-plugin`\n\n![Build](https://img.shields.io/github/actions/workflow/status/LexBorisoff/eslint-plugin/release.yml)\n![NPM Version](https://img.shields.io/npm/v/@lexjs/eslint-plugin)\n![Static Badge](https://img.shields.io/badge/package-ESM--only-ffe536)\n\n- [Installation](#installation)\n- [Usage](#usage-flat-config)\n- [Configs](#configs)\n  - [Recommended](#recommended)\n  - [TypeScript](#typescript)\n- [Utils](#utils)\n  - [useIgnoreFile](#useignorefile)\n\n## Installation\n\n```bash\nnpm install @lexjs/eslint-plugin --save-dev\n```\n\n```bash\npnpm add @lexjs/eslint-plugin --save-dev\n```\n\n```bash\nyarn add @lexjs/eslint-plugin --dev\n```\n\n## Usage (Flat config)\n\n```javascript\n// eslint.config.js\nimport lexjs from '@lexjs/eslint-plugin';\n\nexport default [\n  // other configs\n  ...lexjs.configs.recommended,\n  ...lexjs.configs.typescript,\n  // other configs\n];\n```\n\n## Configs\n\n### Recommended\n\n_**Extends Configs**_\n\n- [ESLint](https://www.npmjs.com/package/@eslint/js)\n  - Recommended\n- [Prettier](https://www.npmjs.com/package/eslint-plugin-prettier)\n  - Recommended\n- [Import Plugin](https://www.npmjs.com/package/eslint-plugin-import)\n  - Recommended\n\n_**Rules**_\n\n```javascript\n{\n  eqeqeq: ['error', 'smart'],\n  'prefer-const': 'warn',\n  'object-shorthand': 'error',\n  'consistent-return': 'error',\n  'no-else-return': ['error', { allowElseIf: false }],\n  'lines-between-class-members': ['error', 'always'],\n  'no-console': 'warn',\n}\n```\n\n_**Import Rules**_\n\n```javascript\n{\n  'import/no-cycle': 'error',\n  'import/no-duplicates': 'error',\n  'import/first': 'error',\n  'import/newline-after-import': 'error',\n  'import/no-named-as-default-member': 'off',\n  'padding-line-between-statements': [\n    'error',\n    { blankLine: 'always', prev: '*', next: 'export' },\n    { blankLine: 'always', prev: 'export', next: '*' },\n    { blankLine: 'any', prev: 'export', next: 'export' },\n  ],\n  'import/order': [\n    'error',\n    {\n      groups: [\n        'builtin',\n        'external',\n        'internal',\n        'parent',\n        'sibling',\n        'index',\n        'object',\n        'type',\n      ],\n      'newlines-between': 'always',\n      alphabetize: {\n        order: 'asc',\n        caseInsensitive: true,\n      },\n    },\n  ],\n  'unused-imports/no-unused-imports': 'error',\n}\n```\n\n### TypeScript\n\n_**Extends Configs**_\n\n- [TypeScript ESLint](https://www.npmjs.com/package/typescript-eslint)\n  - Recommended\n  - ESLint Recommended\n- [Import Plugin](https://www.npmjs.com/package/eslint-plugin-import)\n  - TypeScript\n\n**_Files_**\n\n```javascript\n'**/*.{ts,tsx}'\n```\n\n_**Rules**_\n\n```javascript\n{\n  'no-shadow': 'off',\n  '@typescript-eslint/no-shadow': 'error',\n  'no-use-before-define': 'off',\n  '@typescript-eslint/no-use-before-define': 'error',\n  '@typescript-eslint/no-empty-object-type': 'error',\n  '@typescript-eslint/interface-name-prefix': 'off',\n  '@typescript-eslint/explicit-module-boundary-types': 'off',\n  '@typescript-eslint/no-explicit-any': 'off',\n  '@typescript-eslint/explicit-function-return-type': [\n    'error',\n    {\n      allowExpressions: true,\n    },\n  ],\n  'require-await': 'off',\n  '@typescript-eslint/require-await': 'error',\n  'no-unused-vars': 'off',\n  '@typescript-eslint/no-unused-vars': [\n    'warn',\n    {\n      ignoreRestSiblings: true,\n    },\n  ],\n  '@typescript-eslint/naming-convention': [\n    'error',\n    {\n      selector: 'variable',\n      format: ['camelCase', 'PascalCase', 'UPPER_CASE'],\n      leadingUnderscore: 'allowSingleOrDouble',\n      trailingUnderscore: 'forbid',\n    },\n    {\n      selector: 'enumMember',\n      format: ['PascalCase', 'UPPER_CASE'],\n    },\n  ],\n}\n```\n\n_**Import Settings**_\n\n```javascript\n{\n  'import/resolver': {\n    typescript: {\n      alwaysTryTypes: true,\n    },\n  },\n}\n```\n\n## Utils\n\n### `useIgnoreFile`\n\nConfigure ESLint to ignore certain files and directories by including patterns from a `.gitignore` or any other file with gitignore-style patterns.\n\n**_Type_**\n\n```javascript\nfunction useIgnoreFile(file: string, meta: ImportMeta): FlatConfig;\n```\n\n**_Usage_**\n\n```javascript\n// eslint.config.js\nimport { useIgnoreFile } from '@lexjs/eslint-plugin/utils';\n\nexport default [\n  useIgnoreFile('.gitignore', import.meta),\n  // other configs\n];\n```\n\n\u003e File name must be resolved relative to the ESLint config file.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flexborisoff%2Feslint-plugin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flexborisoff%2Feslint-plugin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flexborisoff%2Feslint-plugin/lists"}