title: Spread Operator is not working ...this.state.attributes
body: <p>Spread operator is not working </p>
  
  <pre><code>&lt;button {...this.state.attributes}&gt;&lt;/button&gt;
  </code></pre>
  
  <p>Getting error "unexpected token this" Below is package.json we have used</p>
  
  <pre><code>       {
    "name": "@coreui/coreui-free-react-admin-template",
    "version": "2.0.5",
    "description": "CoreUI React Open Source Bootstrap 4 Admin Template",
    "license": "MIT",
    "private": true,
    "dependencies": {
      "@coreui/coreui": "^2.0.2",
      "@coreui/coreui-plugin-chartjs-custom-tooltips": "^1.2.0",
      "@coreui/icons": "0.2.0",
      "@coreui/react": "^2.0.4",
      "@rowno/sparkline": "^3.0.1",
      "all": "0.0.0",
      "availity-reactstrap-validation": "^2.0.2",
      "bootstrap": "^4.1.1",
      "chart.js": "^2.7.2",
      "classnames": "^2.2.6",
      "core-js": "^2.5.7",
      "enzyme": "^3.3.0",
      "enzyme-adapter-react-16": "^1.1.1",
      "flag-icon-css": "^3.0.0",
      "font-awesome": "^4.7.0",
      "prop-types": "^15.6.2",
      "react": "^16.4.1",
      "react-avatar": "^3.1.0",
      "react-bootstrap": "^0.32.1",
      "react-chartjs-2": "^2.7.2",
      "react-checkbox-group": "^4.0.1",
      "react-confirm-alert": "^2.0.5",
      "react-dom": "^16.4.1"
      "react-loadable": "^5.4.0",
      "react-loading": "^2.0.3",
      "react-redux": "^5.0.7"
      "react-render-html": "^0.6.0",
      "react-router-config": "^1.0.0-beta.4",
      "react-router-dom": "^4.3.1",
      "react-sortable-pane": "^1.0.2",
      "react-sparklines": "^1.7.0",
      "react-spinners": "^0.3.2",
      "react-stepzilla": "^4.7.2",
      "react-switch": "^3.0.4",
      "react-table": "^6.8.6",
      "react-tabs": "^2.2.2",
      "react-test-renderer": "^16.4.1",
      "react-timekeeper": "^1.0.7",
      "react-toastify": "^4.1.0",
      "reactstrap": "^6.1.0"
      "redux": "^4.0.0",
      "redux-thunk": "^2.3.0"
    },
    "devDependencies": {
      "babel-jest": "^23.0.1",
      "babel-preset-es2015": "^6.24.1",
      "babel-preset-react": "^6.24.1",
      "babel-preset-stage-0": "^6.24.1",
      "node-sass-chokidar": "^1.3.0",
      "npm-run-all": "^4.1.3",
      "react-scripts": "^1.1.4"
    },
    "scripts": {
      "build-css": "node-sass-chokidar --include-path ./node_modules ./src/scss -o ./src/scss",
      "watch-css": "npm run build-css &amp;&amp; node-sass-chokidar --include-path ./node_modules ./src/scss -o ./src/scss --watch --recursive",
      "start-js": "react-scripts start",
      "start": "npm-run-all -p watch-css start-js",
      "build-js": "react-scripts build",
      "build": "npm-run-all build-css build-js",
      "test": "react-scripts test --env=jsdom",
      "eject": "react-scripts eject"
    },
    "babel": {
      "presets": [
        "es2015",
        "react",
        "stage-0"
      ]
    },
    "bugs": {
      "url": "https://github.com/coreui/coreui-free-react-admin-template/issues"
    }
  }
  </code></pre>
  
  <p>We have tried different plugins but no luck.
  transform-object-rest-spread
  getting run time error.
  We have to update button attributes dynamically and spread operator is only option.</p>
  
  <p><a href="https://i.stack.imgur.com/6MYKb.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/6MYKb.png" alt="enter image description here"></a></p>