19.0.2 • Published 5 months ago

@team23/eslint-config-team23-angular v19.0.2

Weekly downloads
-
License
MIT
Repository
github
Last release
5 months ago

eslint-config-team23-angular

A comprehensive ESLint configuration used by TEAM23 for maintaining consistent and strict angular coding standards.

Installation

Add the library to your package.json as a devDependency:

npm i --save-dev @team23/eslint-config-team23-angular

To use the shareable config, import the package inside an eslint.config.js file and add it to the exported array:

// eslint.config.js (ES Module)
import team23Angular from "@team23/eslint-config-team23-angular";

export default [
    ...team23Angular,
];
// eslint.config.js (CommonJS)
const team23Angular = require('@team23/eslint-config-team23-angular');

module.exports = [
    ...team23Angular.default,
];

Overriding Settings

You can override settings from the shareable config by adding them directly into your eslint.config.js file after importing the shareable config. For example:

// eslint.config.js
import team23Angular from "@team23/eslint-config-team23-angular";

export default [
    ...team23Angular,

    // Any settings added here will override team23Angular
    {
        rules: {
            "@angular-eslint/template/cyclomatic-complexity": "error",
        }
    }
];

Compatibility

Nx

If you are extending plugin:@nx/angular in your eslint config, you will use the FlatCompat utility make them available in your flat config. (See the migration guide for more on this process.) While the Nx config can be used this way in parallel with the team23 Angular config, both configs define the plugin @angular-eslint, which is not allowed. To use both configs, you can overwrite the plugins parameter in the FlatCompat result:

// eslint.config.js
import team23Angular from "@team23/eslint-config-team23-angular";

// Prepare compat following the migration guide
// [...]

export default [
    ...team23Angular,

    ...compat
        .extends('plugin:@nx/angular')
        .map(config => ({
            ...config,
            // Replace the plugins object to prevent redefining
            plugins: {},
        })),
];
19.0.1

5 months ago

19.0.0

5 months ago

19.0.2

5 months ago

18.0.0-rc1

10 months ago

17.1.0-rc1

12 months ago

17.1.0-rc2

12 months ago

18.0.2

9 months ago

18.0.1

9 months ago

18.0.0

10 months ago

17.1.0-rc3

11 months ago

17.0.1

1 year ago

16.1.1

2 years ago

16.1.0

2 years ago

16.0.1

2 years ago

16.0.0

2 years ago

17.0.0

2 years ago

15.0.0

2 years ago

15.0.1

2 years ago

2.0.2

3 years ago

2.0.1

3 years ago

2.0.0

3 years ago