@ascendancyy/eslint-config-eva
modified airbnb eslint config
Last updated a month ago by ascendancyy .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @ascendancyy/eslint-config-eva 
SYNC missed versions from official npm registry.

[EVA] Personal ESLint config

Extends Airbnb's base config.

Differences from Airbnb's base config

operator-linebreak

'operator-linebreak': ['warn', 'before', {
  overrides: {
    '=': 'none',
    '?': 'after',
    ':': 'after',
  },
}]

no-debugger

Allow the use of debugger when in development.

'no-debugger': process.env.NODE_ENV !== 'development' ? 'error' : 'off'

no-param-reassign

Added state and el for vue-router and adjusting html elements

'no-param-reassign': ['error', {
  props: true,
  ignorePropertyModificationsFor: [
    'state', // for vuex state
    'acc', // for reduce accumulators
    'accumulator', // for reduce accumulators
    'e', // for e.returnvalue
    'ctx', // for Koa routing
    'req', // for Express requests
    'request', // for Express requests
    'res', // for Express responses
    'response', // for Express responses
    '$scope', // for Angular 1 scopes
    'el', // for el.style
  ],
}]

no-unused-expressions

'no-unused-expressions': ['error', {
  allowShortCircuit: true,
  allowTernary: false,
  allowTaggedTemplates: false,
}]

import/prefer-default-export

'import/prefer-default-export': 'off'

require-atomic-updates

Not yet enabled in Airbnb's base config

'require-atomic-updates': 'error'

Install

$ npm install -D eslint @ascendancyy/eslint-config-eva

or

$ yarn add -D eslint @ascendancyy/eslint-config-eva

Usage

In ESLint (.eslintrc, .eslintrc.js):

{
  "extends": ["@ascendancyy/eslint-config-eva"]
}

Current Tags

  • 3.1.1                                ...           latest (a month ago)

9 Versions

  • 3.1.1                                ...           a month ago
  • 3.1.0                                ...           a month ago
  • 3.0.0                                ...           a year ago
  • 2.0.2                                ...           2 years ago
  • 2.0.1                                ...           2 years ago
  • 2.0.0                                ...           2 years ago
  • 1.2.0                                ...           2 years ago
  • 1.1.0                                ...           2 years ago
  • 1.0.0                                ...           2 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 2
Last Month 3
Dev Dependencies (1)

Copyright 2014 - 2016 © taobao.org |