{"action":"created","issue":{"url":"https://api.github.com/repos/SharePoint/sp-dev-docs/issues/2782","repository_url":"https://api.github.com/repos/SharePoint/sp-dev-docs","labels_url":"https://api.github.com/repos/SharePoint/sp-dev-docs/issues/2782/labels{/name}","comments_url":"https://api.github.com/repos/SharePoint/sp-dev-docs/issues/2782/comments","events_url":"https://api.github.com/repos/SharePoint/sp-dev-docs/issues/2782/events","html_url":"https://github.com/SharePoint/sp-dev-docs/issues/2782","id":370967507,"node_id":"MDU6SXNzdWUzNzA5Njc1MDc=","number":2782,"title":"Error - [webpack] 'dist': web-part.js from UglifyJs Unexpected token: name","user":{"login":"joshburnssp","id":30901352,"node_id":"MDQ6VXNlcjMwOTAxMzUy","avatar_url":"https://avatars2.githubusercontent.com/u/30901352?v=4","gravatar_id":"","url":"https://api.github.com/users/joshburnssp","html_url":"https://github.com/joshburnssp","followers_url":"https://api.github.com/users/joshburnssp/followers","following_url":"https://api.github.com/users/joshburnssp/following{/other_user}","gists_url":"https://api.github.com/users/joshburnssp/gists{/gist_id}","starred_url":"https://api.github.com/users/joshburnssp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joshburnssp/subscriptions","organizations_url":"https://api.github.com/users/joshburnssp/orgs","repos_url":"https://api.github.com/users/joshburnssp/repos","events_url":"https://api.github.com/users/joshburnssp/events{/privacy}","received_events_url":"https://api.github.com/users/joshburnssp/received_events","type":"User","site_admin":false},"labels":[{"id":427158422,"node_id":"MDU6TGFiZWw0MjcxNTg0MjI=","url":"https://api.github.com/repos/SharePoint/sp-dev-docs/labels/area:generator","name":"area:generator","color":"e99695","default":false},{"id":422233691,"node_id":"MDU6TGFiZWw0MjIyMzM2OTE=","url":"https://api.github.com/repos/SharePoint/sp-dev-docs/labels/type:bug","name":"type:bug","color":"c2e0c6","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-10-17T08:57:53Z","updated_at":"2018-10-18T07:34:04Z","closed_at":null,"author_association":"NONE","body":"#### Category\r\n- [x ] Question\r\n- [ ] Typo\r\n- [ x] Bug\r\n- [ ] Additional article idea\r\n\r\n#### Expected or Desired Behavior\r\nrun gulp bundle --ship and gulp package-solution --ship to package the webpart ready for deployment\r\n\r\n#### Observed Behavior\r\n\r\nThe build always fails at step 3 with following error\r\n\r\nError - [webpack] 'dist':\r\nhl-personalised-links-web-part.js from UglifyJs\r\nUnexpected token: name (HlPersonalisedLinksWebPart_HlPersonalisedLinksWebPart) [hl-personalised-links-web-part.js:13725,6]\r\n\r\nwhen checking the hl-personalised-links-web-part.js in the Dist folder, it is duplicating the HlPersonalisedLinksWebPart class name\r\n\r\nclass HlPersonalisedLinksWebPart_HlPersonalisedLinksWebPart extends sp_webpart_base_[\"BaseClientSideWebPart\"]\r\n\r\nthe tsconfig.json file looks like this \r\n\r\n\"compilerOptions\": {\r\n    \"target\": \"es2016\",\r\n    \"forceConsistentCasingInFileNames\": true,\r\n    \"module\": \"esnext\",\r\n    \"moduleResolution\": \"node\",\r\n    \"jsx\": \"react\",\r\n    \"declaration\": true,\r\n    \"sourceMap\": true,\r\n    \"experimentalDecorators\": true,\r\n    \"skipLibCheck\": true,\r\n    \"outDir\": \"lib\",\r\n    \"typeRoots\": [\r\n      \"./node_modules/@types\",\r\n      \"./node_modules/@microsoft\"\r\n    ],\r\n    \"types\": [\r\n      \"es6-promise\",\r\n      \"webpack-env\"\r\n    ],\r\n    \"lib\": [\r\n      \"es2017\",\r\n      \"dom\",\r\n      \"scripthost\"\r\n    ]\r\n  },\r\n  \"include\": [\r\n    \"src/**/*.ts\"\r\n  ],\r\n  \"exclude\": [\r\n    \"node_modules\",\r\n    \"lib\"\r\n  ]\r\n\r\n#### Steps to Reproduce\r\n\r\nrun gulp bundle --ship and package-solution --ship\r\n\r\nThanks for your contribution! Sharing is caring.\r\n"},"comment":{"url":"https://api.github.com/repos/SharePoint/sp-dev-docs/issues/comments/430905692","html_url":"https://github.com/SharePoint/sp-dev-docs/issues/2782#issuecomment-430905692","issue_url":"https://api.github.com/repos/SharePoint/sp-dev-docs/issues/2782","id":430905692,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMDkwNTY5Mg==","user":{"login":"joshburnssp","id":30901352,"node_id":"MDQ6VXNlcjMwOTAxMzUy","avatar_url":"https://avatars2.githubusercontent.com/u/30901352?v=4","gravatar_id":"","url":"https://api.github.com/users/joshburnssp","html_url":"https://github.com/joshburnssp","followers_url":"https://api.github.com/users/joshburnssp/followers","following_url":"https://api.github.com/users/joshburnssp/following{/other_user}","gists_url":"https://api.github.com/users/joshburnssp/gists{/gist_id}","starred_url":"https://api.github.com/users/joshburnssp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joshburnssp/subscriptions","organizations_url":"https://api.github.com/users/joshburnssp/orgs","repos_url":"https://api.github.com/users/joshburnssp/repos","events_url":"https://api.github.com/users/joshburnssp/events{/privacy}","received_events_url":"https://api.github.com/users/joshburnssp/received_events","type":"User","site_admin":false},"created_at":"2018-10-18T07:34:04Z","updated_at":"2018-10-18T07:34:04Z","author_association":"NONE","body":"so my initial reasoning for this was i have an array and needed to use array.includes to get a couple of values. Read somewhere that updating the compiler target would allow me to use .includes.\r\n\r\nJust changed the compiler target back to ES5 and run gulp bundle --ship etc and ran without any errors..."}}
{"actor":{"display_login":"joshburnssp"}}