New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

eslint-config-defaults

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-config-defaults - npm Package Compare versions

Comparing version 8.0.2 to 9.0.0

configurations/node-runtime.js

10

CHANGELOG.md

@@ -0,1 +1,11 @@

## 9.0.0 (2016-02-10)
#### User Facing Changes
* Correct bug where walmart/es6-node enabled ecma features that are unsupported in node@4
* Add babel-eslint to the walmart config to enable proper es-next parsing
* Add node-runtime configuration
* Update README to specify what node version it tracks
* Update airbnb congif from 2.1.1 -> 5.0.0
## 8.0.2 (2016-01-12)

@@ -2,0 +12,0 @@

3

configurations/airbnb/es5.js

@@ -10,4 +10,3 @@ "use strict";

"defaults/rules/eslint/style/airbnb",
"defaults/rules/eslint/variables/airbnb",
"defaults/rules/react/airbnb"
"defaults/rules/eslint/variables/airbnb"
],

@@ -14,0 +13,0 @@ "parser": "babel-eslint",

@@ -7,3 +7,65 @@ "use strict";

"defaults/rules/eslint/node/walmart"
]
],
"ecmaFeatures": {
// Enable arrow functions
"arrowFunctions": true,
// Enable binary literals
"binaryLiterals": true,
// Enable let and const (aka block bindings)
"blockBindings": true,
// Enable classes
"classes": false,
// Enable default function parameters
"defaultParams": false,
// Enable destructuring
"destructuring": false,
// Enable for-of loops
"forOf": true,
// Enable generators
"generators": true,
// Enable modules and global strict mode
"modules": false,
// Enable computed object literal property names
"objectLiteralComputedProperties": true,
// Enable duplicate object literal properties in strict mode
"objectLiteralDuplicateProperties": false,
// Enable object literal shorthand methods
"objectLiteralShorthandMethods": true,
// Enable object literal shorthand properties
"objectLiteralShorthandProperties": true,
// Enable octal literals
"octalLiterals": true,
// Enable the regular expression u flag
"regexUFlag": true,
// Enable the regular expression y flag
"regexYFlag": true,
// Enable the rest parameters
"restParams": true,
// Enable the spread operator for arrays
"spread": true,
// Enable super references inside of functions
"superInFunctions": false,
// Enable template strings
"templateStrings": true,
// Enable code point escapes
"unicodeCodePointEscapes": true,
// Allow return statements in the global scope
"globalReturn": false,
// Enable JSX
"jsx": false,
// Enable support for the experimental object rest/spread properties (IMPORTANT: This is an experimental feature that may change significantly in the future. It's recommended that you do not write rules relying on this functionality unless you are willing to incur maintenance cost when it changes.)
"experimentalObjectRestSpread": false
},
rules: {
// verify super() callings in constructors
"constructor-super": 0,
// disallow modifying variables of class declarations
"no-class-assign": 0,
// disallow modifying variables that are declared using const
"no-dupe-class-members": 0,
// disallow to use this/super before super() calling in constructors.
"no-this-before-super": 0,
// suggest using Reflect methods where applicable
"prefer-reflect": 0
}
};

@@ -8,2 +8,3 @@ "use strict";

],
"parser": "babel-eslint",
"rules": {

@@ -10,0 +11,0 @@ "strict": [2, "global"]

@@ -5,3 +5,3 @@ {

"version" : "8.0.2",
"version" : "9.0.0",
"author" : "Eric Baer <me@ericbaer.com>",

@@ -21,4 +21,6 @@

"devDependencies" : {
"babel-eslint": "4.1.8",
"eslint": "^1.10.3",
"eslint-plugin-filenames": "^0.2.0"
"eslint-plugin-filenames": "0.2.0",
"eslint-plugin-react": "3.12.0"
},

@@ -25,0 +27,0 @@

@@ -39,2 +39,3 @@ <h1 align="center">eslint-config-defaults</h1>

- `defaults/configurations/gulp` - The [Gulp ESLint config](https://github.com/gulpjs/eslint-config-gulp)
- `defaults/configurations/node-runtime` - The config [used for the Node.js runtime](https://github.com/nodejs/node/blob/master/.eslintrc)
- `defaults/configurations/off` - Disable all rules (ESLint's default at 1.0.0+)

@@ -45,7 +46,7 @@ - `defaults/configurations/airbnb/es5` - Config from the [AirBnB Style Guide](https://github.com/airbnb/javascript/tree/master/packages/eslint-config-airbnb)

- `defaults/configurations/walmart/es5-browser` - Walmart ES5 + browser
- `defaults/configurations/walmart/es5-node` - Walmart ES5 + node
- `defaults/configurations/walmart/es5-node` - Walmart ES5 + node < 4.x
- `defaults/configurations/walmart/es5-test` - Walmart ES5 + test
- `defaults/configurations/walmart/es5` - Walmart ES5 config
- `defaults/configurations/walmart/es6-browser` - Walmart ES6 + browser
- `defaults/configurations/walmart/es6-node` - Walmart ES6 + node
- `defaults/configurations/walmart/es6-node` - Walmart ES6 + node 4.x
- `defaults/configurations/walmart/es6-react-test` - Walmart ES6 + react + test

@@ -60,2 +61,3 @@ - `defaults/configurations/walmart/es6-react` - Walmart ES6 + react

- Any React config (`<prefix>-react`) - [eslint-plugin-react](https://www.npmjs.com/package/eslint-plugin-react), [babel-eslint](https://github.com/babel/babel-eslint)
- Any ES-next config (`es6-<suffix>`) - [babel-eslint](https://github.com/babel/babel-eslint)

@@ -107,6 +109,7 @@ To consume and extend a config in ESLint just add the extends attribute to your `.eslintrc`. For

- [eslint-plugin-react](https://www.npmjs.com/package/eslint-plugin-react) 3.12.0
- [eslint-config-airbnb](https://www.npmjs.com/package/eslint-config-airbnb) 2.1.1
- [eslint-config-airbnb](https://www.npmjs.com/package/eslint-config-airbnb) 5.0.0
- [eslint-config-gulp](https://github.com/gulpjs/eslint-config-gulp) 2.0.0
- [Google JavaScript Style Guide](https://github.com/google/styleguide/tree/43d738ab8bb0c797f78506945729946aacbab17d) 43d738ab8b
- [eslint-plugin-filenames](https://www.npmjs.com/package/eslint-plugin-filenames) 0.2.0
- [Node.js](https://github.com/nodejs/node/tree/a84bf2ce68a1ffd5c09c9ff297a56814cd79923f) a84bf2ce68a1ffd5c09c9ff297a56814cd79923f

@@ -119,2 +122,3 @@ ## And A Special Thanks To

* [Google](https://google.github.io/styleguide/javascriptguide.xml) for sharing their styleguide
* [ES-Next Compat Table](https://github.com/kangax/compat-table) for the [excellent docs on node features](https://kangax.github.io/compat-table/es6/#node4)

@@ -121,0 +125,0 @@ ***

@@ -30,3 +30,3 @@ "use strict";

// disallow lexical declarations in case clauses
"no-case-declarations": 0,
"no-case-declarations": 2,
// disallow division operators explicitly at beginning of regular expression

@@ -120,3 +120,3 @@ "no-div-regex": 0,

// require immediate function invocation to be wrapped in parentheses
"wrap-iife": [2, "any"],
"wrap-iife": [2, "outside"],
// require or disallow Yoda conditions

@@ -123,0 +123,0 @@ "yoda": 2

@@ -28,3 +28,3 @@ "use strict";

// require braces in arrow function body
"arrow-body-style": 0,
"arrow-body-style": [2, "as-needed"],
// require parens in arrow function arguments

@@ -53,3 +53,3 @@ "arrow-parens": 0,

// suggest using arrow functions as callbacks
"prefer-arrow-callback": 0,
"prefer-arrow-callback": 2,
// suggest using of const declaration for variables that are never modified after declared

@@ -62,3 +62,3 @@ "prefer-const": 2,

// suggest using template literals instead of strings concatenation
"prefer-template": 0,
"prefer-template": 2,
// disallow generator functions that do not have yield

@@ -65,0 +65,0 @@ "require-yield": 0

@@ -44,3 +44,6 @@ "use strict";

// specify the maximum length of a line in your program
"max-len": [0, 80, 4],
"max-len": [2, 100, 2, {
"ignoreUrls": true,
"ignoreComments": false
}],
// specify the maximum depth callbacks can be nested

@@ -91,3 +94,3 @@ "max-nested-callbacks": 0,

// disallow the use of Boolean literals in conditional expressions
"no-unneeded-ternary": 0,
"no-unneeded-ternary": [2, { "defaultAssignment": false }],
// require or disallow padding inside curly braces

@@ -104,3 +107,3 @@ "object-curly-spacing": [2, "always"],

// require quotes around object literal property names
"quote-props": 0,
"quote-props": [2, "as-needed", { "keywords": false, "unnecessary": true, "numbers": false }],
// specify whether double or single quotes should be used

@@ -107,0 +110,0 @@ "quotes": [2, "single", "avoid-escape"],

@@ -13,5 +13,5 @@ "use strict";

// Prevent missing displayName in a React component definition
"react/display-name": 0,
"react/display-name": [0, { "acceptTranspilerName": false }],
// Forbid certain propTypes
"react/forbid-prop-types": 0,
"react/forbid-prop-types": [0, { "forbid": ["any", "array", "object"] }],
// Enforce boolean attributes notation in JSX

@@ -22,5 +22,8 @@ "react/jsx-boolean-value": [2, "never"],

// Enforce or disallow spaces inside of curly braces in JSX attributes
"react/jsx-curly-spacing": 0,
"react/jsx-curly-spacing": [0, "never", { "allowMultiline": true }],
// Enforce event handler naming conventions in JSX
"react/jsx-handler-names": 0,
"react/jsx-handler-names": [0, {
"eventHandlerPrefix": "handle",
"eventHandlerPropPrefix": "on"
}],
// Validate props indentation in JSX

@@ -31,7 +34,7 @@ "react/jsx-indent-props": [2, 2],

// Limit maximum of props on a single line in JSX
"react/jsx-max-props-per-line": 0,
"react/jsx-max-props-per-line": [0, { "maximum": 1 }],
// Prevent usage of .bind() and arrow functions in JSX props
"react/jsx-no-bind": 2,
// Prevent duplicate props in JSX
"react/jsx-no-duplicate-props": 0,
"react/jsx-no-duplicate-props": [0, { "ignoreCase": false }],
// Prevent usage of isMounted

@@ -48,7 +51,13 @@ "react/no-is-mounted": 2,

// Enforce propTypes declarations alphabetical sorting
"react/jsx-sort-prop-types": 0,
"react/jsx-sort-prop-types": [0, {
"ignoreCase": false,
"callbacksLast": false
}],
// Enforce props alphabetical sorting
"react/jsx-sort-props": 0,
"react/jsx-sort-props": [0, {
"ignoreCase": false,
"callbacksLast": false
}],
// Prevent React to be incorrectly marked as unused
"react/jsx-uses-react": 2,
"react/jsx-uses-react": [2, { "pragma": "React" }],
// Prevent variables used in JSX to be incorrectly marked as unused

@@ -59,3 +68,3 @@ "react/jsx-uses-vars": 2,

// Prevent usage of deprecated methods
"react/no-deprecated": 0,
"react/no-deprecated": [1, { "react": "0.14.0" }],
// Prevent usage of setState in componentDidMount

@@ -68,3 +77,3 @@ "react/no-did-mount-set-state": [2, "allow-in-func"],

// Prevent multiple component definition per file
"react/no-multi-comp": 2,
"react/no-multi-comp": [2, { "ignoreStateless": true }],
// Prevent usage of setState

@@ -79,7 +88,7 @@ "react/no-set-state": 0,

// Prevent missing props validation in a React component definition
"react/prop-types": 2,
"react/prop-types": [2, { "ignore": [], "customValidators": [] }],
// Prevent missing React when using JSX
"react/react-in-jsx-scope": 2,
// Restrict file extensions that may be required
"react/require-extension": 0,
"react/require-extension": [0, { "extensions": [".jsx"] }],
// Prevent extra closing tags for components without children

@@ -86,0 +95,0 @@ "react/self-closing-comp": 2,

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc