0.0.6 • Published 4 years ago

eslint-config-totominc v0.0.6

Weekly downloads
-
License
MIT
Repository
-
Last release
4 years ago

eslint-config-totominc

Some ESLint configs that I use a lot.

Configurations

This eslint-config ships with 4 configurations:

  • totominc: default configuration for pure JS projects, extends airbnb eslint-config and ships with an already configured prettier config.

  • totominc/typescript: recommended configuration for pure TS projects, extends airbnb eslint-config for TypeScript. Set by default the parser to @typescript-eslint/parser with recent ecmaVersion.

  • totominc/vue: recommended configuration for Vue.js projects initialized by the official Vue CLI tool. Extends airbnb eslint-config with specific rules for Vue projets. Also comes with prettier.

  • totominc/vue-typescript: recommended configuration for Vue.js with TypeScript projects generated by the official Vue CLI tool. Extends recommended Vue rules, recommended TypeScript rules, airbnb eslint config and prettier support.

Installation

Local/per-project installation

  1. Install all peer-dependencies from this package, this includes modules that are required by the eslint-config-totominc:

    npx install-peerdeps --dev eslint-config-totominc@latest --yarn
  2. Check your package.json for a list of dev-dependencies.

  3. Create a .eslintrc.js file configuration for ESLint in the root of your project. Then you can extend one of the provided configurations from eslint-config-totominc:

    module.exports = {
      extends: ['totominc'],
    };

Note: you may want to configure your IDE to automatically fix on save. For VSCode, you can use the vscode-eslint extension and configure your settings.json like this:

{
  "editor.formatOnSave": true,
  "editor.formatOnPaste": true,
  "editor.codeActionsOnSave": {
    "source.fixAll.eslint": true
  }
}

Global installation

  1. Install all peer-dependencies from this package, this includes modules that are required by the eslint-config-totominc:

    npx install-peerdeps --global eslint-config-totominc@latest --yarn
  2. Create a global .eslintrc.js file configuration for ESLint in your home folder (e.g. ~/.eslintrc.js). Then you can extend one of the provided configurations from eslint-config-totominc:

    module.exports = {
      extends: ['totominc'],
    };
0.0.5

4 years ago

0.0.6

4 years ago

0.0.4

4 years ago

0.0.3

4 years ago

0.0.2

4 years ago

0.0.1

4 years ago