{"id":39132080,"url":"https://github.com/y-scope/eslint-config-yscope","last_synced_at":"2026-01-20T17:23:40.227Z","repository":{"id":225025593,"uuid":"764888133","full_name":"y-scope/eslint-config-yscope","owner":"y-scope","description":null,"archived":false,"fork":false,"pushed_at":"2025-10-14T17:56:51.000Z","size":186,"stargazers_count":0,"open_issues_count":12,"forks_count":5,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-10-14T17:58:16.962Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/y-scope.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}},"created_at":"2024-02-28T22:21:48.000Z","updated_at":"2025-10-14T17:56:56.000Z","dependencies_parsed_at":"2024-02-28T23:30:50.052Z","dependency_job_id":"dfd3cae4-8a8d-4ddf-967f-bf33285db3ae","html_url":"https://github.com/y-scope/eslint-config-yscope","commit_stats":null,"previous_names":["y-scope/eslint-config-yscope"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/y-scope/eslint-config-yscope","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/y-scope%2Feslint-config-yscope","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/y-scope%2Feslint-config-yscope/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/y-scope%2Feslint-config-yscope/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/y-scope%2Feslint-config-yscope/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/y-scope","download_url":"https://codeload.github.com/y-scope/eslint-config-yscope/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/y-scope%2Feslint-config-yscope/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28518618,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-17T18:55:29.170Z","status":"ssl_error","status_checked_at":"2026-01-17T18:55:03.375Z","response_time":85,"last_error":"SSL_read: 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":"2026-01-17T21:18:54.108Z","updated_at":"2026-01-17T21:18:54.210Z","avatar_url":"https://github.com/y-scope.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# eslint-config-yscope\n\nThis repository contains ESLint [\"flat\"][eslint-flat-config] configurations for various JavaScript\nenvironments under the `yscope` namespace. Our configurations are designed to enforce a consistent\ncoding style and catch common bugs, making your codebase more maintainable and error-free.\n\n## Installation\n\nTo get started with `eslint-config-yscope`, you can install the package:\n\n```shell\nnpm install --save-dev eslint-config-yscope\n# or\nyarn add --dev eslint-config-yscope\n```\n\n### For Older Node.js Versions\n\nThis package requires ESLint 9, which in turn requires Node.js 18 or above. If you are using an\nolder version of Node.js, you can use version `0.0.32` of this package, which is compatible with\nESLint 8. Detailed setup instructions for this version are available in the \n[older version's README][readme-0.0.32].\n\n## Usage\n\nAfter installation, you can create an `eslint.config.mjs` configuration file in the root directory\nof your project and export an array of configuration objects.\n\n### Available Configurations\n\nSome configurations are provided as standalone configuration objects, which can be directly\nreferenced once imported:\n- `CommonConfig`: A general ESLint configuration suitable for a wide range of JavaScript projects.\n- `JestConfig`: A specialized ESLint configuration for Jest files.\n- `MeteorConfig`: A specialized ESLint configuration for Meteor projects.\n\nThe other configurations are provided as a group of configuration objects stored in an array. To use\nthese configurations, you need to utilize the \"spread\" (`...`) syntax to unpack the configuration\nobjects into your own configuration array:\n- `StylisticConfigArray`: A configuration for stylistic formatting. It is typically combined with\n  `CommonConfig`, as shown in the [ESLint config examples](#eslint-config-examples).\n- `ReactConfigArray`: A specialized ESLint configuration for React applications.\n- `TsConfigArray`: A specialized ESLint configuration for TypeScript projects. A helper\n  `createTsConfigOverride` is also provided. See [ESLint config examples](#eslint-config-examples)\n  for details on how to set it up.\n\n\n### ESLint config examples\n\n1. For use with a CommonJS Node.js project:\n    ```javascript\n    import Globals from \"globals\";\n    \n    import CommonConfig from \"eslint-config-yscope/CommonConfig.mjs\";\n    import StylisticConfigArray from \"eslint-config-yscope/StylisticConfigArray.mjs\";\n    \n    \n    const EslintConfig = [\n        CommonConfig,\n        ...StylisticConfigArray,\n        {\n            languageOptions: {\n                globals: {\n                    ...Globals.node,\n                },\n            },\n        },\n        {\n            rules: {\n                // Your own overrides\n            },\n        },\n    ];\n    \n    \n    export default EslintConfig;\n    ```\n\n2. For use with a JavaScript React.js project:\n    ```javascript\n    import CommonConfig from \"eslint-config-yscope/CommonConfig.mjs\";\n    import ReactConfigArray from \"eslint-config-yscope/ReactConfigArray.mjs\";\n    import StylisticConfigArray from \"eslint-config-yscope/StylisticConfigArray.mjs\";\n    \n    \n    const EslintConfig = [\n        CommonConfig,\n        ...StylisticConfigArray,\n        ...ReactConfigArray,\n    ];\n    \n    \n    export default EslintConfig;\n    ```\n\n3. For use with a TypeScript React.js project:\n    ```javascript\n    import CommonConfig from \"eslint-config-yscope/CommonConfig.mjs\";\n    import ReactConfigArray from \"eslint-config-yscope/ReactConfigArray.mjs\";\n    import StylisticConfigArray from \"eslint-config-yscope/StylisticConfigArray.mjs\";\n    import TsConfigArray from \"eslint-config-yscope/TsConfigArray.mjs\";\n    \n    \n    const EslintConfig = [\n        CommonConfig,\n    \n        ...TsConfigArray,\n\n        // NOTE: `StylisticConfigArray` must be placed after `TsConfigArray` to override stylistic\n        // rules within `TsConfigArray` (we can't remove the stylistic rules from `TsConfigArray`\n        // since they come from a preset that `TsConfigArray` extends).\n        ...StylisticConfigArray,\n    \n        ...ReactConfigArray,\n    ];\n    \n    \n    export default EslintConfig;\n    ```\n   \n4. For use with a TypeScript project with multiple `tsconfig.json` files: In projects that include\n   multiple `tsconfig.json` files for different source types, such as a Vite project created from\n   the `react-ts` template, you can use the helper function `createTsConfigOverride` to generate\n   configuration overrides. This ensures proper handling of imports and resolution.\n   ```javascript\n   import CommonConfig from \"eslint-config-yscope/CommonConfig.mjs\";\n   import ReactConfigArray from \"eslint-config-yscope/ReactConfigArray.mjs\";\n   import StylisticConfigArray from \"eslint-config-yscope/StylisticConfigArray.mjs\";\n   import TsConfigArray, {createTsConfigOverride} from \"eslint-config-yscope/TsConfigArray.mjs\";\n   \n   \n   const EslintConfig = [\n       {\n           ignores: [\n               \"dist/\",\n               \"node_modules/\",\n           ],\n       },\n       CommonConfig,\n   \n       ...TsConfigArray,\n       createTsConfigOverride(\n           [\n               \"src/**/*.ts\",\n               \"src/**/*.tsx\",\n           ],\n           \"tsconfig.app.json\"\n       ),\n       createTsConfigOverride(\n           [\"vite.config.ts\"],\n           \"tsconfig.node.json\"\n       ),\n   \n       ...StylisticConfigArray,\n       ...ReactConfigArray,\n   ];\n   \n   \n   export default EslintConfig;\n   ```\n\n## Customization\n\nEach configuration can be further customized and extended as per your project's needs. You can\noverride specific rules by adding them to your ESLint configuration file.\n\n## Contributing\n\nWe welcome contributions to the `eslint-config-yscope`! If you have suggestions or improvements,\nfeel free to open an issue or a pull request.\n\n[eslint-flat-config]: https://eslint.org/docs/v9.x/use/configure/migration-guide\n[license]: https://github.com/y-scope/eslint-config-yscope/blob/main/LICENSE\n[readme-0.0.32]: https://github.com/y-scope/eslint-config-yscope/blob/f75571723ff1a6fd734ab82b4a399c2c1c92c5fb/README.md#for-older-nodejs-versions\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fy-scope%2Feslint-config-yscope","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fy-scope%2Feslint-config-yscope","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fy-scope%2Feslint-config-yscope/lists"}