eslint-config-prettiest
v1.1.0
Published
An ESLint shareable config for consistent code style
Downloads
283
Maintainers
Readme
eslint-config-prettiest
An ESLint shareable configuration to enforce consistent code style and best practices.
Overview
eslint-config-prettiest provides a consistent, extendable ESLint configuration to help teams or projects align with best practices and maintain code quality across repositories.
Installation
To install the configuration and its peer dependencies, run:
pnpm install --save-dev eslint eslint-config-prettiest
If your config requires plugins (e.g., eslint-plugin-react, @typescript-eslint), make sure to install them as well:
pnpm install --save-dev eslint-plugin-react @typescript-eslint/eslint-plugin @typescript-eslint/parser
Or, if you don't mind about the amount of development dependencies, you can simply run:
pnpm dlx install-peerdeps eslint-config-prettiest -D -P pnpm
Usage
To use the config in your project, extend it in your ESLint configuration file (e.g., eslint.config.js
):
eslint.config.js
import { URL } from 'node:url';
import eslintConfigure from 'eslint-config-prettiest';
const prettierrc = new URL('./.prettierrc', import.meta.url).pathname;
export default [
...eslintConfigure({ useTypeScript: true, useReact: true, prettierrc }),
];
Customizing
You can add or override specific rules in your ESLint configuration to adjust to project-specific needs. For example:
export default [
...eslintConfigure({ useTypeScript: true, useReact: true, prettierrc }),
{
rules: {
...
},
},
];
Contributing
Contributions are welcome! Please follow the steps below to contribute:
- Fork the repository.
- Make changes in a feature branch.
- Open a pull request with a description of your changes.
License
This project is licensed under the MIT License.