{"action":"created","issue":{"url":"https://api.github.com/repos/mozilla/delivery-console/issues/150","repository_url":"https://api.github.com/repos/mozilla/delivery-console","labels_url":"https://api.github.com/repos/mozilla/delivery-console/issues/150/labels{/name}","comments_url":"https://api.github.com/repos/mozilla/delivery-console/issues/150/comments","events_url":"https://api.github.com/repos/mozilla/delivery-console/issues/150/events","html_url":"https://github.com/mozilla/delivery-console/issues/150","id":318465489,"node_id":"MDU6SXNzdWUzMTg0NjU0ODk=","number":150,"title":"antd \"whole package usage\" warnings when running the tests","user":{"login":"magopian","id":167767,"node_id":"MDQ6VXNlcjE2Nzc2Nw==","avatar_url":"https://avatars1.githubusercontent.com/u/167767?v=4","gravatar_id":"","url":"https://api.github.com/users/magopian","html_url":"https://github.com/magopian","followers_url":"https://api.github.com/users/magopian/followers","following_url":"https://api.github.com/users/magopian/following{/other_user}","gists_url":"https://api.github.com/users/magopian/gists{/gist_id}","starred_url":"https://api.github.com/users/magopian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/magopian/subscriptions","organizations_url":"https://api.github.com/users/magopian/orgs","repos_url":"https://api.github.com/users/magopian/repos","events_url":"https://api.github.com/users/magopian/events{/privacy}","received_events_url":"https://api.github.com/users/magopian/received_events","type":"User","site_admin":false},"labels":[{"id":852728480,"node_id":"MDU6TGFiZWw4NTI3Mjg0ODA=","url":"https://api.github.com/repos/mozilla/delivery-console/labels/P3","name":"P3","color":"ffa32c","default":false},{"id":958474520,"node_id":"MDU6TGFiZWw5NTg0NzQ1MjA=","url":"https://api.github.com/repos/mozilla/delivery-console/labels/techdebt","name":"techdebt","color":"5319e7","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-04-27T16:04:45Z","updated_at":"2018-06-28T08:15:00Z","closed_at":"2018-06-28T08:15:00Z","author_association":"CONTRIBUTOR","body":"When running the tests, a lot of the following warnings are displayed:\r\n\r\n```\r\nYou are using a whole package of antd, please use https://www.npmjs.com/package/babel-plugin-import to reduce app bundle size\r\n```\r\n\r\nI've tried literally everything I could think about to fix this issue, but haven't managed to. I believe it's because jest doesn't use webpack, and thus doesn't use `config-overrides.js` (see https://github.com/timarney/react-app-rewired#extended-configuration-options), which injects the `babel-import-plugin` that should fix this).\r\nI tried:\r\n- using the method from the link above to have Jest use the config-overrides (but there's an error when trying to inject the plugin, some keys are missing from the `config`)\r\n- adding a `babel` entry in the package.json\r\n```json\r\n  \"babel\": {\r\n    \"plugins\": [[\"import\", { \"libraryName\": \"antd\", \"style\": true }]]\r\n  }\r\n```\r\n- adding a `.babelrc` file\r\n```json\r\n{\r\n  \"plugins\": [[\"import\", { \"libraryName\": \"antd\", \"style\": true }]]\r\n}\r\n```"},"comment":{"url":"https://api.github.com/repos/mozilla/delivery-console/issues/comments/400951735","html_url":"https://github.com/mozilla/delivery-console/issues/150#issuecomment-400951735","issue_url":"https://api.github.com/repos/mozilla/delivery-console/issues/150","id":400951735,"node_id":"MDEyOklzc3VlQ29tbWVudDQwMDk1MTczNQ==","user":{"login":"rehandalal","id":987136,"node_id":"MDQ6VXNlcjk4NzEzNg==","avatar_url":"https://avatars2.githubusercontent.com/u/987136?v=4","gravatar_id":"","url":"https://api.github.com/users/rehandalal","html_url":"https://github.com/rehandalal","followers_url":"https://api.github.com/users/rehandalal/followers","following_url":"https://api.github.com/users/rehandalal/following{/other_user}","gists_url":"https://api.github.com/users/rehandalal/gists{/gist_id}","starred_url":"https://api.github.com/users/rehandalal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rehandalal/subscriptions","organizations_url":"https://api.github.com/users/rehandalal/orgs","repos_url":"https://api.github.com/users/rehandalal/repos","events_url":"https://api.github.com/users/rehandalal/events{/privacy}","received_events_url":"https://api.github.com/users/rehandalal/received_events","type":"User","site_admin":false},"created_at":"2018-06-28T08:15:00Z","updated_at":"2018-06-28T08:15:00Z","author_association":"MEMBER","body":"This appears to be fixed"}}
{"actor":{"display_login":"rehandalal"}}