Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/forivall/eslint-plugin-cupcake
Some sweet eslint rules
https://github.com/forivall/eslint-plugin-cupcake
hacktoberfest
Last synced: 3 months ago
JSON representation
Some sweet eslint rules
- Host: GitHub
- URL: https://github.com/forivall/eslint-plugin-cupcake
- Owner: forivall
- License: mit
- Created: 2022-06-19T21:25:27.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-10-24T16:12:30.000Z (about 1 year ago)
- Last Synced: 2024-04-14T12:49:58.697Z (9 months ago)
- Topics: hacktoberfest
- Language: JavaScript
- Homepage:
- Size: 36.1 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# eslint-plugin-cupcake
[![npm version](https://img.shields.io/npm/v/eslint-plugin-cupcake.svg)](https://www.npmjs.com/package/eslint-plugin-cupcake)
[![build status](https://github.com/forivall/eslint-plugin-cupcake/actions/workflows/main.yml/badge.svg)](https://github.com/forivall/eslint-plugin-cupcake/actions/workflows/main.yml)A collection of eslint rules for consistent code standards.
## Installation
Use [npm](https://www.npmjs.com/) or a compatible tool to install.
```
$ npm install --save-dev eslint eslint-plugin-cupcake
```### Requirements
- Node.js v14.15.0 or newer versions.
- ESLint v6.8.0 or newer versions.## Usage
Write your config file such as `.eslintrc.yml`.
```yml
plugins:
- cupcake
rules:
cupcake/case-block: error
```See also [Configuring ESLint](https://eslint.org/docs/user-guide/configuring).
## Configs
- `cupcake/recommended` ... enables the recommended rules.
## Rules
### Stylistic Issues
| Rule ID | Description | |
|:--------|:------------|:--:|
| [cupcake/case-block](./docs/rules/case-block.md) | Enforces block statements in case blocks | ⭐️✒️ |
| [cupcake/declaration-order](./docs/rules/declaration-order.md) | Enforces order of variable declarations | ⭐️ |
| [cupcake/func-style](./docs/rules/func-style.md) | Enforce the consistent use of either `function` declarations or expressions | ⭐️ |## Semantic Versioning Policy
This plugin follows [Semantic Versioning](http://semver.org/) and [ESLint's Semantic Versioning Policy](https://github.com/eslint/eslint#semantic-versioning-policy).
## Changelog
- [GitHub Releases](https://github.com/forivall/eslint-plugin-cupcake/releases)
## Contributing
Welcome your contribution!
See also [ESLint Contribution Guide](https://eslint.org/docs/developer-guide/contributing/).
### Development Tools
- `npm test` runs tests and measures coverage.
- `npm version ` updates the package version. And it updates `lib/configs/recommended.js`, `lib/index.js`, and `README.md`'s rule table. See also [npm version CLI command](https://docs.npmjs.com/cli/version).
- `npm run add-rule ` creates three files to add a new rule.