Socket
Socket
Sign inDemoInstall

eslint-plugin-destructuring

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-plugin-destructuring - npm Package Compare versions

Comparing version 2.1.0 to 2.2.0

3

CHANGELOG.md

@@ -5,2 +5,5 @@ # Change Log

## [2.2.0] - 2019-10-14
- Allow renaming invalid identifiers
## [2.1.0] - 2017-02-71

@@ -7,0 +10,0 @@ - Added new 'in-methods-params' rule

4

lib/rules/no-rename.js

@@ -15,4 +15,4 @@ 'use strict';

Property: function Property(node) {
if (node.parent.type === 'ObjectPattern' && node.shorthand === false && node.value && node.value.type === 'Identifier') {
context.report(node, 'Do not use destructuring rename.');
if (node.parent.type === 'ObjectPattern' && node.shorthand === false && node.value && node.value.type === 'Identifier' && node.key.type !== 'Literal') {
context.report(node, 'Do not use destructuring rename for valid identifiers.');
}

@@ -19,0 +19,0 @@ }

{
"name": "eslint-plugin-destructuring",
"version": "2.1.0",
"version": "2.2.0",
"author": "Luke Page",

@@ -5,0 +5,0 @@ "description": "destructuring specific linting rules for ESLint",

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