@putout/plugin-merge-destructuring-properties
🐊Putout plugin adds ability to merge destructuring properties
Last updated 4 months ago by coderaiser .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @putout/plugin-merge-destructuring-properties 
SYNC missed versions from official npm registry.

@putout/plugin-merge-destructuring-properties NPM version

The destructuring assignment syntax is a JavaScript expression that makes it possible to unpack values from arrays, or properties from objects, into distinct variables.

(c) MDN

????Putout plugin adds ability to merge destructuring properties. Merged with @putout/plugin-destructuring.

Checkout in ????Putout Editor.

Install

npm i @putout/plugin-merge-destructuring-properties

Rule

Rule merge-destructuring-properties is enabled by default, to disable add to .putout.json:

{
    "rules": {
        "merge-destructuring-properties": "off"
    }
}

❌ Example of incorrect code

const {one} = require('numbers');
const {two} = require('numbers');

✅ Example of correct code

const {one, two} = require('numbers');

Assignment

❌ Example of incorrect code

({from} = data);
({to} = data);
({names} = data);

✅ Example of correct code

({
    from,
    to,
    names,
} = data);

License

MIT

Current Tags

  • 12.3.1                                ...           latest (4 months ago)

30 Versions

  • 12.3.1                                ...           4 months ago
  • 12.3.0                                ...           10 months ago
  • 12.2.0                                ...           10 months ago
  • 12.1.2                                ...           10 months ago
  • 12.1.1                                ...           10 months ago
  • 12.1.0                                ...           10 months ago
  • 12.0.0                                ...           10 months ago
  • 11.0.0                                ...           a year ago
  • 10.0.0                                ...           a year ago
  • 9.0.0                                ...           2 years ago
  • 8.0.0                                ...           3 years ago
  • 7.0.0                                ...           3 years ago
  • 6.2.1                                ...           4 years ago
  • 6.2.0                                ...           4 years ago
  • 6.1.0                                ...           4 years ago
  • 6.0.0                                ...           4 years ago
  • 5.2.1                                ...           5 years ago
  • 5.2.0                                ...           5 years ago
  • 5.1.0                                ...           5 years ago
  • 5.0.1                                ...           5 years ago
  • 5.0.0                                ...           6 years ago
  • 4.0.0                                ...           6 years ago
  • 3.1.0                                ...           6 years ago
  • 3.0.0                                ...           6 years ago
  • 2.0.0                                ...           6 years ago
  • 1.2.0                                ...           7 years ago
  • 1.1.0                                ...           7 years ago
  • 1.0.2                                ...           7 years ago
  • 1.0.1                                ...           7 years ago
  • 1.0.0                                ...           7 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 1
Last Month 10
Dependencies (0)
None
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |