Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/po4tion/eslint-plugin-component
eslint plugin for everyone.
https://github.com/po4tion/eslint-plugin-component
component eslint eslint-config react
Last synced: about 1 month ago
JSON representation
eslint plugin for everyone.
- Host: GitHub
- URL: https://github.com/po4tion/eslint-plugin-component
- Owner: po4tion
- License: mit
- Created: 2023-04-21T00:55:33.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-12-01T17:08:54.000Z (about 1 year ago)
- Last Synced: 2024-10-30T02:32:49.424Z (3 months ago)
- Topics: component, eslint, eslint-config, react
- Language: JavaScript
- Homepage: https://www.npmjs.com/package/eslint-plugin-component
- Size: 188 KB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# eslint-plugin-component
This open source library is developed to improve the developer's experience. 😆
## Installation
You'll first need to install [ESLint](https://eslint.org/):
```sh
npm i -D eslint
#OR
yarn add -D eslint
#OR
pnpm add -D eslint
```Next, install `eslint-plugin-component`:
```sh
npm install -D eslint-plugin-component
#OR
yarn add -D eslint-plugin-component
#OR
pnpm add -D eslint-plugin-component
```## Usage
This plugin only works in the components folder path.
Add `component` to the plugins section of your `.eslintrc` configuration file. You can omit the `eslint-plugin-` prefix:
```json
{
"plugins": ["component"]
}
```## Rules
| Rule | Description |
|--------|----------|
| [component/jsx-pascal-in-component](docs/jsx-pascal-in-component.md) | Change the first letter of the component to uppercase if it is lowercase. |
| [component/number-easy-read](docs/number-easy-read.md) | Enforce number literals for readability. |
| [component/constants](docs/constants.md) | Enforce capital letters in constant variable names. |## Contributing
We welcome contribution from everyone in the community. Read below for detailed contribution guide.
[CONTRIBUTING](CONTRIBUTING.md)