Skeleton node module for an ESLint plugin.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
config
rules
test
.editorconfig
.eslintignore
.eslintrc
.gitignore
CHANGELOG.md
LICENSE
README.md
index.js
package.json

README.md

eslint-plugin-skeleton

Note

I will update this module only on request. If you want an update, create a pull request or raise an issue.

Description

ESLint Plugin with recommended rules and mixins for the different environments of an Angular web application.

Integration

Either insert it as a local folder with a relative path in the package.json (see akSkeleton) or use it as node module.

Your root .eslintrc needs to look the following:

{
  "extends": "./node_modules/eslint-plugin-skeleton/config/eslintrc.base"
}

The .eslintrc located in your source files (e.g. src/) should extend the browser mixin:

{
  "extends": "../node_modules/eslint-plugin-skeleton/config/mixins/browser"
}

The .eslintrc located in your test files (e.g. test/) should extend the test mixin:

{
  "extends": "../node_modules/eslint-plugin-skeleton/config/mixins/test"
}

Configuration & Mixins

  1. The eslintrc.base contains all the defaults and main rules. It ensures that the root files are linted as a node environment.
  2. The browser mixin sets up the rules and environment for linting client-side scripts.
  3. The test mixin is exclusively used for the test environment.