$ npm install @putout/plugin-extract-object-properties
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.
npm i @putout/plugin-extract-object-properties -D
{
"rules": {
"extract-object-properties/equal-deep": "on",
"extract-object-properties/not-equal-deep": "on"
}
}
const {replaceWith} = a.operate;
const {isIdentifier} = a.types;
const {
operator,
types,
} = a;
const {replaceWith} = operator;
const {isIdentifier} = types;
const {replaceWith} = a;
const {isIdentifier} = a.types;
const {replaceWith, types} = a;
const {isIdentifier} = types;
MIT
© 2010 - cnpmjs.org x YWFE | Home | YWFE