Skip to content

acadevmy/eslint-plugin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

195af17 Β· Feb 11, 2025

History

36 Commits
Jan 17, 2025
Dec 3, 2024
Feb 11, 2025
Dec 2, 2024
Dec 2, 2024
Dec 2, 2024
Feb 11, 2025
Dec 2, 2024
Jan 20, 2025
Feb 11, 2025
Jan 20, 2025
Feb 11, 2025
Jan 20, 2025
Jan 17, 2025
Dec 3, 2024
Jan 20, 2025
Dec 3, 2024

Repository files navigation

@devmy/eslint-plugin

This library provides ESLint configurations with the recommended rules from the Devmy team for TypeScript and popular frameworks like React, Angular. It helps you enforce consistent code style, avoid common pitfalls, and improve the overall quality and maintainability of your projects.

Installation

npm:

npm install --save-dev @devmy/eslint-plugin

pnpm:

pnpm add -D @devmy/eslint-plugin

yarn

yarn add --dev @devmy/eslint-plugin

bun

bun add -d @devmy/eslint-plugin

Note: If you installed ESLint globally then you must also install @devmy/eslint-plugin globally.

Usage

If you're using flat configuration:

With flat configuration, just import the plugin and away you go:

// .eslintrc.js
const pluginDevmy = require('@devmy/eslint-plugin');

module.exports = {
  extends: [
    pluginDevmy.configs.recommended
  ]
};

With legacy configuration, add @devmy/eslint-plugin to the plugins section of your .eslintrc configuration file:

{
  "extends": ["plugin:@devmy/eslint-plugin/recommended"]
}

Configurations

Configuration full name Description
recommended @devmy/eslint-plugin/recommended The base configuration for TypeScript projects.
angular-recommended @devmy/eslint-plugin/angular-recommended Extends the "recommended" configuration with rules specific to Angular projects.
angular-template-recommended @devmy/eslint-plugin/angular-template-recommended Provides recommended rules for Angular templates.
cypress-recommended @devmy/eslint-plugin/cypress-recommended Provides recommended rules for Cypress projects.
jest-recommended @devmy/eslint-plugin/jest-recommended Provides recommended rules for jest tests.

Rules

Key

  • βœ… = recommended
  • πŸ”§ = fixable
  • πŸ’‘ = has suggestions
Rule Description βœ… πŸ”§ πŸ’‘
prefer-class-bindings Ensures the usage of class bindings instead of ngClass for elements

Contributing

We welcome contributions to this project! If you find any issues or have suggestions for new rules or configurations, please open an issue or submit a pull request.