@putout/plugin-extract-object-properties
putout plugin adds ability to extract object properties into variable
Last updated 5 years ago by coderaiser .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @putout/plugin-extract-object-properties 
SYNC missed versions from official npm registry.

@putout/plugin-extract-object-properties NPM version

The destructuring assignment makes possible to unpack values from objects into distinct variables.

(c) MDN

????Putout plugin adds ability to apply destructuring to extract object properties. Merged with @putout/plugin-destructuring.

Install

npm i @putout/plugin-extract-object-properties -D

Rule

{
    "rules": {
        "extract-object-properties/equal-deep": "on",
        "extract-object-properties/not-equal-deep": "on"
    }
}

Equal Deep

❌ Example of incorrect code

const {replaceWith} = a.operate;
const {isIdentifier} = a.types;

✅ Example of correct code

const {operator, types} = a;

const {replaceWith} = operator;
const {isIdentifier} = types;

Not Equal Deep

❌ Example of incorrect code

const {replaceWith} = a;
const {isIdentifier} = a.types;

✅ Example of correct code

const {replaceWith, types} = a;

const {isIdentifier} = types;

License

MIT

Current Tags

  • 10.0.1                                ...           latest (4 months ago)

36 Versions

  • 10.0.1                                ...           4 months ago
  • 10.0.0                                ...           10 months ago
  • 9.0.0                                ...           3 years ago
  • 8.3.1                                ...           4 years ago
  • 8.3.0                                ...           4 years ago
  • 8.2.0                                ...           4 years ago
  • 8.1.0                                ...           4 years ago
  • 8.0.1                                ...           4 years ago
  • 8.0.0                                ...           4 years ago
  • 7.0.0                                ...           4 years ago
  • 6.0.1                                ...           5 years ago
  • 6.0.0                                ...           5 years ago
  • 5.0.0                                ...           5 years ago
  • 4.0.0                                ...           6 years ago
  • 3.2.3                                ...           6 years ago
  • 3.2.2                                ...           6 years ago
  • 3.2.1                                ...           6 years ago
  • 3.2.0                                ...           6 years ago
  • 3.1.3                                ...           6 years ago
  • 3.1.2                                ...           6 years ago
  • 3.1.1                                ...           6 years ago
  • 3.1.0                                ...           6 years ago
  • 3.0.0                                ...           6 years ago
  • 2.0.0                                ...           7 years ago
  • 1.3.0                                ...           7 years ago
  • 1.2.3                                ...           7 years ago
  • 1.2.2                                ...           7 years ago
  • 1.2.1                                ...           7 years ago
  • 1.2.0                                ...           7 years ago
  • 1.1.2                                ...           7 years ago
  • 1.1.1                                ...           7 years ago
  • 1.1.0                                ...           7 years ago
  • 1.0.3                                ...           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 0
Last Month 3
Dependencies (0)
None
Dev Dependencies (10)
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |