Socket
Socket
Sign inDemoInstall

eslint-plugin-react

Package Overview
Dependencies
Maintainers
1
Versions
208
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-plugin-react - npm Package Compare versions

Comparing version 3.0.0 to 3.1.0

14

History.md

@@ -0,1 +1,15 @@

3.1.0 / 2015-07-28
==================
* update dependencies
* add event handlers to no-unknown-property ([#164][] @mkenyon)
* add customValidators option to prop-types ([#145][] @CalebMorris)
* fix comment handling in jsx-curly-spacing ([#165][])
* documentation improvements ([#167][] @ngbrown)
[#164]: https://github.com/yannickcr/eslint-plugin-react/pull/164
[#156]: https://github.com/yannickcr/eslint-plugin-react/issues/145
[#165]: https://github.com/yannickcr/eslint-plugin-react/issues/165
[#167]: https://github.com/yannickcr/eslint-plugin-react/pull/167
3.0.0 / 2015-07-21

@@ -2,0 +16,0 @@ ==================

4

lib/rules/jsx-curly-spacing.js

@@ -152,2 +152,6 @@ /**

if (first === penultimate && second === last) {
return;
}
validateBraceSpacing(node, first, second, penultimate, last);

@@ -154,0 +158,0 @@ }

@@ -25,3 +25,8 @@ /**

'frameBorder', 'hrefLang', 'htmlFor', 'httpEquiv', 'marginHeight', 'marginWidth', 'maxLength', 'mediaGroup',
'noValidate', 'radioGroup', 'readOnly', 'rowSpan', 'spellCheck', 'srcDoc', 'srcSet', 'tabIndex', 'useMap',
'noValidate', 'onBlur', 'onChange', 'onClick', 'onContextMenu', 'onCopy', 'onCut', 'onDoubleClick',
'onDrag', 'onDragEnd', 'onDragEnter', 'onDragExit', 'onDragLeave', 'onDragOver', 'onDragStart', 'onDrop',
'onFocus', 'onInput', 'onKeyDown', 'onKeyPress', 'onKeyUp', 'onMouseDown', 'onMouseEnter', 'onMouseLeave',
'onMouseMove', 'onMouseOut', 'onMouseOver', 'onMouseUp', 'onPaste', 'onScroll', 'onSubmit', 'onTouchCancel',
'onTouchEnd', 'onTouchMove', 'onTouchStart', 'onWheel',
'radioGroup', 'readOnly', 'rowSpan', 'spellCheck', 'srcDoc', 'srcSet', 'tabIndex', 'useMap',
'itemProp', 'itemScope', 'itemType', 'itemRef', 'itemID'

@@ -28,0 +33,0 @@ ];

@@ -21,2 +21,3 @@ /**

var ignored = configuration.ignore || [];
var customValidators = configuration.customValidators || [];

@@ -77,2 +78,11 @@ var componentList = new ComponentList();

/**
* Checks if prop should be validated by plugin-react-proptypes
* @param {String} validator Name of validator to check.
* @returns {Boolean} True if validator should be checked by custom validator.
*/
function hasCustomValidator(validator) {
return customValidators.indexOf(validator) !== -1;
}
/**
* Checks if the component must be validated

@@ -209,2 +219,11 @@ * @param {Object} component The component to process

if (
value &&
value.callee &&
value.callee.object &&
hasCustomValidator(value.callee.object.name)
) {
return true;
}
if (
value.type === 'MemberExpression' &&

@@ -616,2 +635,8 @@ value.property &&

}
},
customValidators: {
type: 'array',
items: {
type: 'string'
}
}

@@ -618,0 +643,0 @@ },

9

package.json
{
"name": "eslint-plugin-react",
"version": "3.0.0",
"version": "3.1.0",
"author": "Yannick Croissant <yannick.croissant+npm@gmail.com>",

@@ -26,6 +26,5 @@ "description": "React specific linting rules for ESLint",

"devDependencies": {
"babel-eslint": "3.1.23",
"coveralls": "2.11.2",
"eslint": "1.0.0-rc-1",
"eslint-tester": "0.8.2",
"babel-eslint": "4.0.5",
"coveralls": "2.11.3",
"eslint": "1.0.0-rc-3",
"istanbul": "0.3.17",

@@ -32,0 +31,0 @@ "mocha": "2.2.5"

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