message: Extract behavior in MemberExpressionOccurrence
diff: @@ -215,16 +215,22 @@ function createOccurrence(
  path: ast.NodePath,
  loc: ast.SourceLocation
  ): Occurrence {
  - return ast.canBeShorthand(path)
  - ? new ShorthandOccurrence(path, loc)
  - : new Occurrence(path, loc);
  + if (ast.canBeShorthand(path)) {
  + return new ShorthandOccurrence(path, loc);
  + }
  +
  + if (path.isMemberExpression()) {
  + return new MemberExpressionOccurrence(path, loc);
  + }
  +
  + return new Occurrence(path, loc);
  }
  class Occurrence {
  path: ast.NodePath;
  loc: ast.SourceLocation;
  - private variable: Variable;
  + protected variable: Variable;
  constructor(path: ast.NodePath, loc: ast.SourceLocation) {
  this.path = path;
  @@ -260,15 +266,8 @@ class Occurrence {
  }
  toVariableDeclaration(code: Code): Code {
  - const extractedCode = ast.isJSXText(this.path.node)
  - ? `"${code}"`
  - : ast.isMemberExpression(this.path.node) && !this.path.node.computed
  - ? ast.generate(this.path.node.object)
  - : code;
  - const name =
  - ast.isMemberExpression(this.path.node) && !this.path.node.computed
  - ? `{ ${this.variable.name} }`
  - : this.variable.name;
  + const extractedCode = ast.isJSXText(this.path.node) ? `"${code}"` : code;
  + const { name } = this.variable;
  return `const ${name} = ${extractedCode};\n${this.indentation}`;
  }
  @@ -309,6 +308,29 @@ class ShorthandOccurrence extends Occurrence {
  }
  }
  +class MemberExpressionOccurrence extends Occurrence {
  + path: ast.NodePath<ast.MemberExpression>;
  +
  + constructor(
  + path: ast.NodePath<ast.MemberExpression>,
  + loc: ast.SourceLocation
  + ) {
  + super(path, loc);
  + this.path = path;
  + }
  +
  + toVariableDeclaration(code: Code): Code {
  + if (this.path.node.computed) {
  + return super.toVariableDeclaration(code);
  + }
  +
  + const extractedCode = ast.generate(this.path.node.object);
  + const name = `{ ${this.variable.name} }`;
  +
  + return `const ${name} = ${extractedCode};\n${this.indentation}`;
  + }
  +}
  +
  class Variable {
  private _name = "extracted";
  private path: ast.NodePath;
  