Skip to content

ng-all/eslint-config

Repository files navigation

@ng-all/eslint-config

eslint-config for Angular projects

Usage

  • get the package from npm
$ npm install @ng-all/eslint-config -D
  • just extends it in your eslint config file eg. .eslintrc.json
{
    // ...
    "extends": [
        // ...
        "@ng-all"
        // ...
    ]
    // ...
}
  • linting
$ npx eslint ./ --ext .ts --ext .js --ext .html
  • ng lint with @angular-eslint/builder configured in angular.json
{
    // ...
    "lint": {
        "builder": "@angular-eslint/builder:lint",
        "options": {
            "lintFilePatterns": [
                "./**/*.ts",
                "./**/*.html"
            ]
        }
    }
    // ...
}
  • VS Code Settings for eslint extension

update eslint extension's settings to let it check html file in VS Code

{
    // ./.vscode/settings.json
    // ...
    "eslint.options": {
        "extensions": [
            ".ts",
            ".js",
            ".html"
        ]
    },
    "eslint.validate": [
        "javascript",
        "typescript",
        "html"
    ]
    // ...
}

Dependency

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published